@vnejs/contracts.vars 0.1.1 → 0.1.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.
@@ -0,0 +1,9 @@
1
+ export declare const LINE_KEYWORDS: {
2
+ readonly GLOBAL: "global";
3
+ };
4
+ export declare const CONSTANTS: {
5
+ readonly LINE_KEYWORDS: {
6
+ readonly GLOBAL: "global";
7
+ };
8
+ };
9
+ export type Constants = typeof CONSTANTS;
package/dist/const.js ADDED
@@ -0,0 +1,6 @@
1
+ export const LINE_KEYWORDS = {
2
+ GLOBAL: "global",
3
+ };
4
+ export const CONSTANTS = {
5
+ LINE_KEYWORDS,
6
+ };
package/dist/index.d.ts CHANGED
@@ -1,10 +1,13 @@
1
1
  import "@vnejs/module";
2
2
  import "@vnejs/shared";
3
+ import { CONSTANTS } from "./const.js";
3
4
  import { SUBSCRIBE_EVENTS } from "./events.js";
4
5
  import type { ModuleGlobalStateVars } from "./module-global-state.js";
5
6
  export declare const PLUGIN_NAME: "VARS";
6
7
  export type PluginName = typeof PLUGIN_NAME;
7
8
  export type { ModuleGlobalStateVars } from "./module-global-state.js";
9
+ export { CONSTANTS, LINE_KEYWORDS } from "./const.js";
10
+ export type { Constants } from "./const.js";
8
11
  export { SUBSCRIBE_EVENTS };
9
12
  export type { SubscribeEvents } from "./events.js";
10
13
  export type VarValue = string | number | boolean;
@@ -50,4 +53,6 @@ declare module "@vnejs/module" {
50
53
  declare module "@vnejs/shared" {
51
54
  interface VnePluginEventsMap extends Record<typeof PLUGIN_NAME, typeof SUBSCRIBE_EVENTS> {
52
55
  }
56
+ interface VnePluginConstantsMap extends Record<typeof PLUGIN_NAME, typeof CONSTANTS> {
57
+ }
53
58
  }
package/dist/index.js CHANGED
@@ -2,4 +2,5 @@ import "@vnejs/module";
2
2
  import "@vnejs/shared";
3
3
  import { SUBSCRIBE_EVENTS } from "./events.js";
4
4
  export const PLUGIN_NAME = "VARS";
5
+ export { CONSTANTS, LINE_KEYWORDS } from "./const.js";
5
6
  export { SUBSCRIBE_EVENTS };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vnejs/contracts.vars",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Contracts for @vnejs/plugins.vars",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/src/const.ts ADDED
@@ -0,0 +1,9 @@
1
+ export const LINE_KEYWORDS = {
2
+ GLOBAL: "global",
3
+ } as const;
4
+
5
+ export const CONSTANTS = {
6
+ LINE_KEYWORDS,
7
+ } as const;
8
+
9
+ export type Constants = typeof CONSTANTS;
package/src/index.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import "@vnejs/module";
2
2
  import "@vnejs/shared";
3
3
 
4
+ import { CONSTANTS } from "./const.js";
4
5
  import { SUBSCRIBE_EVENTS } from "./events.js";
5
6
  import type { ModuleGlobalStateVars } from "./module-global-state.js";
6
7
 
@@ -8,6 +9,8 @@ export const PLUGIN_NAME = "VARS" as const;
8
9
  export type PluginName = typeof PLUGIN_NAME;
9
10
 
10
11
  export type { ModuleGlobalStateVars } from "./module-global-state.js";
12
+ export { CONSTANTS, LINE_KEYWORDS } from "./const.js";
13
+ export type { Constants } from "./const.js";
11
14
  export { SUBSCRIBE_EVENTS };
12
15
  export type { SubscribeEvents } from "./events.js";
13
16
 
@@ -61,4 +64,6 @@ declare module "@vnejs/module" {
61
64
 
62
65
  declare module "@vnejs/shared" {
63
66
  interface VnePluginEventsMap extends Record<typeof PLUGIN_NAME, typeof SUBSCRIBE_EVENTS> {}
67
+
68
+ interface VnePluginConstantsMap extends Record<typeof PLUGIN_NAME, typeof CONSTANTS> {}
64
69
  }