@ynor/ynor 1.0.1 → 1.0.2

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/ynor.js CHANGED
@@ -74,7 +74,7 @@ program
74
74
  preview: "vite preview"
75
75
  },
76
76
  devDependencies: {
77
- "ynor": "latest",
77
+ "@ynor/ynor": "latest",
78
78
  "vite": "^8.0.0"
79
79
  }
80
80
  };
@@ -116,7 +116,7 @@ program
116
116
 
117
117
  // Create main.js
118
118
  console.log(chalk.dim(' 📄 Creating src/main.js...'));
119
- const mainJs = `import { runtime, mount, store } from 'ynor';
119
+ const mainJs = `import { runtime, mount, store } from '@ynor/ynor';
120
120
  import App from './App.ynor';
121
121
 
122
122
  console.log('🚀 Starting .ynor application...');
@@ -211,7 +211,7 @@ if (import.meta.hot) {
211
211
  // Create vite.config.js
212
212
  console.log(chalk.dim(' 📄 Creating vite.config.js...'));
213
213
  const viteConfig = `import { defineConfig } from 'vite';
214
- import { ynorPlugin } from 'ynor/plugin';
214
+ import { ynorPlugin } from '@ynor/ynor/plugin';
215
215
 
216
216
  export default defineConfig({
217
217
  plugins: [ynorPlugin()],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ynor/ynor",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "⚡ Lightweight next-gen JS extension framework like Svelte",
5
5
  "type": "module",
6
6
  "main": "./src/lib/core/index.js",
@@ -311,7 +311,7 @@ transformScript(script) {
311
311
  relativePath = '.';
312
312
  }
313
313
 
314
- return relativePath + '/runtime.js';
314
+ return '@ynor/ynor/runtime';
315
315
  }
316
316
 
317
317
  // src/lib/core/compiler.js - Fix processTemplate
@@ -1,43 +1,62 @@
1
1
  // src/lib/core/index.js
2
- export {
3
- VERSION,
4
- compile,
5
- compileModule,
6
- migrate,
7
- parse,
8
- parseCss,
9
- preprocess,
10
- print,
11
- walk,
12
- AST,
13
- YnorCompiler
14
- } from './compiler.js';
2
+ import { VERSION, YnorCompiler, AST } from './compiler.js';
3
+ import { YnorRuntime, YnorComponent, runtime, store, mount } from './runtime.js';
4
+ import { ynorPlugin } from './plugin.js';
5
+
6
+ // Error handling utilities
7
+ import {
8
+ YnorError,
9
+ YnorCompilerError,
10
+ YnorRuntimeError,
11
+ YnorTemplateError,
12
+ YnorComponentError,
13
+ handleError,
14
+ warn,
15
+ info,
16
+ success
17
+ } from './utils/errors.js';
15
18
 
16
- export { ynorPlugin } from './plugin.js';
19
+ // CLI utilities
20
+ import { createProject, buildProject, devProject } from './cli.js';
17
21
 
22
+ // Export everything
18
23
  export {
24
+ VERSION,
25
+ YnorCompiler,
26
+ AST,
19
27
  YnorRuntime,
20
28
  YnorComponent,
21
29
  runtime,
22
30
  store,
23
- mount
24
- } from './runtime.js';
31
+ mount,
32
+ ynorPlugin,
33
+ YnorError,
34
+ YnorCompilerError,
35
+ YnorRuntimeError,
36
+ YnorTemplateError,
37
+ YnorComponentError,
38
+ handleError,
39
+ warn,
40
+ info,
41
+ success,
42
+ createProject,
43
+ buildProject,
44
+ devProject
45
+ };
25
46
 
26
47
  // Default export
27
48
  export default {
28
49
  VERSION,
29
- compile,
30
- compileModule,
31
- migrate,
32
- parse,
33
- parseCss,
34
- preprocess,
35
- print,
36
- walk,
37
- AST,
38
50
  YnorCompiler,
39
- ynorPlugin,
51
+ AST,
52
+ YnorRuntime,
53
+ YnorComponent,
40
54
  runtime,
41
55
  store,
42
- mount
56
+ mount,
57
+ ynorPlugin,
58
+ handleError,
59
+ warn,
60
+ info,
61
+ success
43
62
  };