diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/App.html | 16 | ||||
-rw-r--r-- | src/components/Test1/Test1.html | 1 | ||||
-rw-r--r-- | src/components/Test2/Test2.html | 1 | ||||
-rw-r--r-- | src/main.js | 10 |
4 files changed, 28 insertions, 0 deletions
diff --git a/src/App.html b/src/App.html new file mode 100644 index 0000000..d1a4dc5 --- /dev/null +++ b/src/App.html @@ -0,0 +1,16 @@ +<label>Hello {{name}}!</label> +Template : <Test1></Test1> +Template : <Test2></Test2> +<style> + h1 { + color: purple; + } +</style> + +<script> + import Test1 from './components/Test1/Test1.html'; + import Test2 from './components/Test2/Test2.html'; + export default { + components :{Test1, Test2} + } +</script>
\ No newline at end of file diff --git a/src/components/Test1/Test1.html b/src/components/Test1/Test1.html new file mode 100644 index 0000000..a1ceaa2 --- /dev/null +++ b/src/components/Test1/Test1.html @@ -0,0 +1 @@ +<label>Test 1</label> diff --git a/src/components/Test2/Test2.html b/src/components/Test2/Test2.html new file mode 100644 index 0000000..c12c1a5 --- /dev/null +++ b/src/components/Test2/Test2.html @@ -0,0 +1 @@ +<label>Test 2</label>
\ No newline at end of file diff --git a/src/main.js b/src/main.js new file mode 100644 index 0000000..9af70cb --- /dev/null +++ b/src/main.js @@ -0,0 +1,10 @@ +import App from './App.html'; + +const app = new App({ + target: document.body, + data: { + name: 'This is my name' + } +}); + +export default app;
\ No newline at end of file |