create-nodality-vue 1.0.0-beta.7 → 1.0.0-beta.70

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/index.js CHANGED
@@ -43,7 +43,7 @@ function createVueProject(projectName) {
43
43
  },
44
44
  dependencies: {
45
45
  vue: "^3.0.0",
46
- nodality: "^1.0.0-beta.4",
46
+ nodality: "^1.0.0-beta.70",
47
47
  },
48
48
  devDependencies: {
49
49
  vite: "^4.0.0",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-nodality-vue",
3
- "version": "1.0.0-beta.7",
3
+ "version": "1.0.0-beta.70",
4
4
  "description": "A scaffolding tool for creating Vue.js projects integrated with Nodality.",
5
5
  "main": "bin/index.js",
6
6
  "bin": {
@@ -1,24 +1,43 @@
1
1
  <template>
2
- <h1>Hello Vue</h1>
3
- <HelloWorld :text="textInstance" v-model:msg="welcomeMessage" />
2
+ <HelloWorld :text="textInstance" v-model:msg="welcomeMessage"/>
4
3
  </template>
5
4
 
6
5
  <script>
7
- import HelloWorld from "./components/HelloWorld.vue";
8
- import { Text } from "nodality";
9
-
6
+ import HelloWorld from './components/HelloWorld.vue'
7
+ import {Text} from "nodality";
10
8
  export default {
9
+ name: 'App',
10
+ components: {
11
+ HelloWorld
12
+ },
13
+
14
+ watch: {
15
+ // Watch for changes to welcomeMessage and recreate the instance
16
+ welcomeMessage() {
17
+ console.log(this.welcomeMessage) // THIS WORKS
18
+ this.textInstance = new Text(this.welcomeMessage).set({ size: "S1", color: "#1abc9c" });
19
+ },
20
+ },
11
21
  data() {
12
22
  return {
13
- welcomeMessage: "Welcome to Nodality + Vue.js",
14
- textInstance: null,
15
- };
23
+ welcomeMessage: "Welcome to Your Vue.js App", // Define a reactive property
24
+ textInstance: null
25
+ }
16
26
  },
17
- created() {
18
- this.textInstance = new Text(this.welcomeMessage).set({
19
- size: "S1",
20
- color: "#1abc9c",
21
- });
27
+ created() {
28
+ // Initialize the Text instance when the component is created
29
+ this.textInstance = new Text(this.welcomeMessage).set({ size: "S1", color: "#1abc9c" });
22
30
  },
23
- };
31
+ }
24
32
  </script>
33
+
34
+ <style>
35
+ #app {
36
+ font-family: Avenir, Helvetica, Arial, sans-serif;
37
+ -webkit-font-smoothing: antialiased;
38
+ -moz-osx-font-smoothing: grayscale;
39
+ text-align: center;
40
+ color: #2c3e50;
41
+ margin-top: 60px;
42
+ }
43
+ </style>
@@ -1,6 +1,5 @@
1
1
  <script setup>
2
2
  import { useTemplateRef, onMounted, defineProps, defineEmits, watch } from 'vue'
3
- //import {Text} from "../lib/TextCopy.js";
4
3
 
5
4
  // Define props to accept the msg value
6
5
  const props = defineProps({
@@ -33,5 +32,6 @@ function updateMessage(event) {
33
32
  </script>
34
33
 
35
34
  <template>
36
- <h2>Hello from static Vue</h2>
35
+ <input ref="my-input" :value="msg" @input="updateMessage" />
36
+ <div ref="my-comp"/>
37
37
  </template>