Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
smart3d-vue3
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
SVI
svi-templates
smart3d-vue3
Commits
bc24ff2b
Commit
bc24ff2b
authored
Nov 02, 2022
by
曾沂轮
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新成API模板
parent
ec4c5e15
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
9 deletions
+13
-9
README.md
README.md
+2
-2
package.json
template/package.json
+1
-1
Viewer.vue
template/src/components/Viewer.vue
+10
-6
No files found.
README.md
View file @
bc24ff2b
# svi-cli smart3d-vue3 Template
> 一个基于vite搭建的vue + typescript + smart3d
-vue组件库
应用模板,提供给svi-cli脚手架获取.
> 提供内部用Vue3 + smart3d
-vue
开发页面的初始模板
> 一个基于vite搭建的vue + typescript + smart3d
api
应用模板,提供给svi-cli脚手架获取.
> 提供内部用Vue3 + smart3d开发页面的初始模板
> 主要包含 `vue`, `smart3d-vue`, `@smart/eslint-config-typescript` 智能的规范
## Usage / 用法
...
...
template/package.json
View file @
bc24ff2b
...
...
@@ -11,7 +11,7 @@
"prepare"
:
"husky install"
},
"dependencies"
:
{
"smart3d
-vue"
:
"^1.2
.0"
,
"smart3d
"
:
"^2.0
.0"
,
"vue"
:
"^3.2.13"
},
"devDependencies"
:
{
...
...
template/src/components/Viewer.vue
View file @
bc24ff2b
<
script
setup
lang=
"ts"
>
import
type
{
Viewer
}
from
'smart3d'
;
import
{
SMap
}
from
'smart3d-
vue'
;
import
{
Viewer
}
from
'smart3d'
;
import
{
onMounted
,
ref
}
from
'
vue'
;
const
viewerReady
=
(
viewer
:
Viewer
)
=>
{
console
.
log
(
viewer
);
};
const
containerRef
=
ref
();
onMounted
(()
=>
{
const
container
=
containerRef
.
value
;
viewer
=
new
Viewer
(
container
);
console
.
log
(
viewer
);
})
</
script
>
<
template
>
<
SMap
class=
"viewer"
@
ready=
"viewerReady"
/
>
<
div
ref=
"containerRef"
></div
>
</
template
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment