@kithinji/pod 1.0.0

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.
Files changed (98) hide show
  1. package/build.js +22 -0
  2. package/dist/main.js +4464 -0
  3. package/dist/main.js.map +7 -0
  4. package/dist/types/add/component/component.d.ts +5 -0
  5. package/dist/types/add/component/component.d.ts.map +1 -0
  6. package/dist/types/add/component/index.d.ts +2 -0
  7. package/dist/types/add/component/index.d.ts.map +1 -0
  8. package/dist/types/add/index.d.ts +4 -0
  9. package/dist/types/add/index.d.ts.map +1 -0
  10. package/dist/types/add/module/index.d.ts +2 -0
  11. package/dist/types/add/module/index.d.ts.map +1 -0
  12. package/dist/types/add/module/module.d.ts +3 -0
  13. package/dist/types/add/module/module.d.ts.map +1 -0
  14. package/dist/types/add/new/index.d.ts +2 -0
  15. package/dist/types/add/new/index.d.ts.map +1 -0
  16. package/dist/types/config/config.d.ts +18 -0
  17. package/dist/types/config/config.d.ts.map +1 -0
  18. package/dist/types/config/index.d.ts +2 -0
  19. package/dist/types/config/index.d.ts.map +1 -0
  20. package/dist/types/dev/index.d.ts +2 -0
  21. package/dist/types/dev/index.d.ts.map +1 -0
  22. package/dist/types/dev/project.d.ts +9 -0
  23. package/dist/types/dev/project.d.ts.map +1 -0
  24. package/dist/types/dev/server.d.ts +2 -0
  25. package/dist/types/dev/server.d.ts.map +1 -0
  26. package/dist/types/docker/docker.d.ts +2 -0
  27. package/dist/types/docker/docker.d.ts.map +1 -0
  28. package/dist/types/docker/index.d.ts +2 -0
  29. package/dist/types/docker/index.d.ts.map +1 -0
  30. package/dist/types/macros/expand_macros.d.ts +48 -0
  31. package/dist/types/macros/expand_macros.d.ts.map +1 -0
  32. package/dist/types/macros/index.d.ts +3 -0
  33. package/dist/types/macros/index.d.ts.map +1 -0
  34. package/dist/types/macros/macro_executer.d.ts +12 -0
  35. package/dist/types/macros/macro_executer.d.ts.map +1 -0
  36. package/dist/types/main.d.ts +13 -0
  37. package/dist/types/main.d.ts.map +1 -0
  38. package/dist/types/plugins/analyzers/graph.d.ts +25 -0
  39. package/dist/types/plugins/analyzers/graph.d.ts.map +1 -0
  40. package/dist/types/plugins/css/index.d.ts +7 -0
  41. package/dist/types/plugins/css/index.d.ts.map +1 -0
  42. package/dist/types/plugins/generators/generate_controller.d.ts +2 -0
  43. package/dist/types/plugins/generators/generate_controller.d.ts.map +1 -0
  44. package/dist/types/plugins/generators/generate_rsc.d.ts +2 -0
  45. package/dist/types/plugins/generators/generate_rsc.d.ts.map +1 -0
  46. package/dist/types/plugins/generators/generate_server_component.d.ts +2 -0
  47. package/dist/types/plugins/generators/generate_server_component.d.ts.map +1 -0
  48. package/dist/types/plugins/generators/tsx_server_stub.d.ts +2 -0
  49. package/dist/types/plugins/generators/tsx_server_stub.d.ts.map +1 -0
  50. package/dist/types/plugins/index.d.ts +4 -0
  51. package/dist/types/plugins/index.d.ts.map +1 -0
  52. package/dist/types/plugins/my.d.ts +10 -0
  53. package/dist/types/plugins/my.d.ts.map +1 -0
  54. package/dist/types/plugins/transformers/j2d.d.ts +11 -0
  55. package/dist/types/plugins/transformers/j2d.d.ts.map +1 -0
  56. package/dist/types/store/index.d.ts +2 -0
  57. package/dist/types/store/index.d.ts.map +1 -0
  58. package/dist/types/store/store.d.ts +14 -0
  59. package/dist/types/store/store.d.ts.map +1 -0
  60. package/dist/types/utils/cases.d.ts +4 -0
  61. package/dist/types/utils/cases.d.ts.map +1 -0
  62. package/dist/types/utils/create.d.ts +12 -0
  63. package/dist/types/utils/create.d.ts.map +1 -0
  64. package/dist/types/utils/index.d.ts +3 -0
  65. package/dist/types/utils/index.d.ts.map +1 -0
  66. package/package.json +44 -0
  67. package/src/add/component/component.ts +496 -0
  68. package/src/add/component/index.ts +1 -0
  69. package/src/add/index.ts +3 -0
  70. package/src/add/module/index.ts +1 -0
  71. package/src/add/module/module.ts +521 -0
  72. package/src/add/new/index.ts +135 -0
  73. package/src/config/config.ts +141 -0
  74. package/src/config/index.ts +1 -0
  75. package/src/dev/index.ts +1 -0
  76. package/src/dev/project.ts +45 -0
  77. package/src/dev/server.ts +190 -0
  78. package/src/docker/docker.ts +452 -0
  79. package/src/docker/index.ts +1 -0
  80. package/src/macros/expand_macros.ts +791 -0
  81. package/src/macros/index.ts +2 -0
  82. package/src/macros/macro_executer.ts +189 -0
  83. package/src/main.ts +95 -0
  84. package/src/plugins/analyzers/graph.ts +291 -0
  85. package/src/plugins/css/index.ts +25 -0
  86. package/src/plugins/generators/generate_controller.ts +308 -0
  87. package/src/plugins/generators/generate_rsc.ts +274 -0
  88. package/src/plugins/generators/generate_server_component.ts +279 -0
  89. package/src/plugins/generators/tsx_server_stub.ts +295 -0
  90. package/src/plugins/index.ts +3 -0
  91. package/src/plugins/my.ts +274 -0
  92. package/src/plugins/transformers/j2d.ts +1014 -0
  93. package/src/store/index.ts +1 -0
  94. package/src/store/store.ts +44 -0
  95. package/src/utils/cases.ts +15 -0
  96. package/src/utils/create.ts +26 -0
  97. package/src/utils/index.ts +2 -0
  98. package/tsconfig.json +27 -0
@@ -0,0 +1,5 @@
1
+ export declare function addComponent(name: string, processedComponents?: Set<string>): void;
2
+ export declare function getComponentDependencies(name: string, visited?: Set<string>): string[];
3
+ export declare function printDependencyTree(name: string, indent?: string): void;
4
+ export declare function listComponents(): void;
5
+ //# sourceMappingURL=component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../../../src/add/component/component.ts"],"names":[],"mappings":"AAmJA,wBAAgB,YAAY,CAC1B,IAAI,EAAE,MAAM,EACZ,mBAAmB,GAAE,GAAG,CAAC,MAAM,CAAa,QAqE7C;AAED,wBAAgB,wBAAwB,CACtC,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,GAAG,CAAC,MAAM,CAAa,GAC/B,MAAM,EAAE,CAmBV;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,GAAE,MAAW,GAAG,IAAI,CAW3E;AAED,wBAAgB,cAAc,IAAI,IAAI,CAUrC"}
@@ -0,0 +1,2 @@
1
+ export * from "./component";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/add/component/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC"}
@@ -0,0 +1,4 @@
1
+ export * from "./component";
2
+ export * from "./new";
3
+ export * from "./module";
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/add/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./module";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/add/module/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,3 @@
1
+ export declare function addFeature(name: string): void;
2
+ export declare function addModule(name: string, baseDir: string): void;
3
+ //# sourceMappingURL=module.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../../src/add/module/module.ts"],"names":[],"mappings":"AAKA,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,QAQtC;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,QA8CtD"}
@@ -0,0 +1,2 @@
1
+ export declare function addNew(name: string): void;
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/add/new/index.ts"],"names":[],"mappings":"AAKA,wBAAgB,MAAM,CAAC,IAAI,EAAE,MAAM,QA+BlC"}
@@ -0,0 +1,18 @@
1
+ import { Store } from "@/store";
2
+ import type { Plugin } from "esbuild";
3
+ export type PodPlugin = (store: Store) => Plugin;
4
+ export interface PodConfig {
5
+ name: string;
6
+ build?: {
7
+ outDir?: string;
8
+ sourcemap?: boolean;
9
+ minify?: boolean;
10
+ };
11
+ plugins?: Array<PodPlugin>;
12
+ client_plugins?: Array<PodPlugin>;
13
+ server_plugins?: Array<PodPlugin>;
14
+ }
15
+ export declare function loadConfig(root?: string): Promise<PodConfig>;
16
+ export declare function getDefaultConfig(): PodConfig;
17
+ export declare function mergeConfig(defaults: PodConfig, userConfig: PodConfig): PodConfig;
18
+ //# sourceMappingURL=config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/config/config.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEtC,MAAM,MAAM,SAAS,GAAG,CAAC,KAAK,EAAE,KAAK,KAAK,MAAM,CAAC;AAEjD,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE;QACN,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,SAAS,CAAC,EAAE,OAAO,CAAC;QACpB,MAAM,CAAC,EAAE,OAAO,CAAC;KAClB,CAAC;IACF,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;IAC3B,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;IAClC,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;CACnC;AASD,wBAAsB,UAAU,CAC9B,IAAI,GAAE,MAAsB,GAC3B,OAAO,CAAC,SAAS,CAAC,CAkBpB;AA8DD,wBAAgB,gBAAgB,IAAI,SAAS,CAY5C;AAED,wBAAgB,WAAW,CACzB,QAAQ,EAAE,SAAS,EACnB,UAAU,EAAE,SAAS,GACpB,SAAS,CAcX"}
@@ -0,0 +1,2 @@
1
+ export * from "./config";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/config/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA"}
@@ -0,0 +1,2 @@
1
+ export * from "./server";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/dev/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,9 @@
1
+ import * as ts from "typescript";
2
+ export declare class Project {
3
+ program: ts.Program;
4
+ checker: ts.TypeChecker;
5
+ constructor(entryPoints: string[]);
6
+ isPublicFile(sourceFile: ts.SourceFile): boolean;
7
+ isInteractiveFile(sourceFile: ts.SourceFile): boolean;
8
+ }
9
+ //# sourceMappingURL=project.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../../src/dev/project.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,YAAY,CAAC;AAEjC,qBAAa,OAAO;IACX,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC;IACpB,OAAO,EAAE,EAAE,CAAC,WAAW,CAAC;gBAEnB,WAAW,EAAE,MAAM,EAAE;IAWjC,YAAY,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,GAAG,OAAO;IAchD,iBAAiB,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,GAAG,OAAO;CAatD"}
@@ -0,0 +1,2 @@
1
+ export declare function startDevServer(): Promise<void>;
2
+ //# sourceMappingURL=server.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/dev/server.ts"],"names":[],"mappings":"AAyDA,wBAAsB,cAAc,IAAI,OAAO,CAAC,IAAI,CAAC,CAoIpD"}
@@ -0,0 +1,2 @@
1
+ export declare function dockerize(env?: "dev" | "prod"): Promise<void>;
2
+ //# sourceMappingURL=docker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"docker.d.ts","sourceRoot":"","sources":["../../../src/docker/docker.ts"],"names":[],"mappings":"AAeA,wBAAsB,SAAS,CAAC,GAAG,GAAE,KAAK,GAAG,MAAe,iBAwB3D"}
@@ -0,0 +1,2 @@
1
+ export * from "./docker";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/docker/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,48 @@
1
+ import ts from "typescript";
2
+ import { Store } from "@/store";
3
+ export interface MacroContext {
4
+ node: ts.CallExpression;
5
+ sourceFile: ts.SourceFile;
6
+ ts: typeof ts;
7
+ factory: ts.NodeFactory;
8
+ store: Store;
9
+ graph: MacroDependencyGraph;
10
+ get program(): ts.Program;
11
+ get checker(): ts.TypeChecker;
12
+ error(msg: string): never;
13
+ resolveNodeValue(node: ts.Node): any;
14
+ resolveIdentifier(identifier: ts.Identifier): ts.Node;
15
+ }
16
+ interface MacroNode {
17
+ key: string;
18
+ variableName: string;
19
+ node: ts.CallExpression;
20
+ sourceFile: ts.SourceFile;
21
+ filePath: string;
22
+ dependencies: Set<string>;
23
+ astResult?: ts.Node;
24
+ computed: boolean;
25
+ }
26
+ declare class MacroDependencyGraph {
27
+ private nodes;
28
+ private projectRoot;
29
+ private typeChecker?;
30
+ constructor(projectRoot: string);
31
+ setTypeChecker(checker: ts.TypeChecker): void;
32
+ createKey(sourceFile: ts.SourceFile, variableName: string): string;
33
+ addNode(key: string, variableName: string, node: ts.CallExpression, sourceFile: ts.SourceFile): void;
34
+ getNode(key: string): MacroNode | undefined;
35
+ addDependency(fromKey: string, toKey: string): void;
36
+ setResult(key: string, astResult: ts.Node): void;
37
+ getResult(key: string): ts.Node | undefined;
38
+ isComputed(key: string): boolean;
39
+ topologicalSort(): string[];
40
+ clear(): void;
41
+ getNodesForFile(filePath: string): MacroNode[];
42
+ }
43
+ export declare function getGlobalMacroGraph(projectRoot: string): MacroDependencyGraph;
44
+ export declare function resetGlobalMacroGraph(): void;
45
+ export declare function extractValueFromNode(node: ts.Node): any | undefined;
46
+ export declare function expandMacros(source: string, filePath: string, projectRoot?: string): Promise<string>;
47
+ export {};
48
+ //# sourceMappingURL=expand_macros.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"expand_macros.d.ts","sourceRoot":"","sources":["../../../src/macros/expand_macros.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,YAAY,CAAC;AAI5B,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,EAAE,CAAC,cAAc,CAAC;IACxB,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC;IAC1B,EAAE,EAAE,OAAO,EAAE,CAAC;IACd,OAAO,EAAE,EAAE,CAAC,WAAW,CAAC;IACxB,KAAK,EAAE,KAAK,CAAC;IACb,KAAK,EAAE,oBAAoB,CAAC;IAC5B,IAAI,OAAO,IAAI,EAAE,CAAC,OAAO,CAAC;IAC1B,IAAI,OAAO,IAAI,EAAE,CAAC,WAAW,CAAC;IAC9B,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAAC;IAC1B,gBAAgB,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,GAAG,GAAG,CAAC;IACrC,iBAAiB,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,GAAG,EAAE,CAAC,IAAI,CAAC;CACvD;AAED,UAAU,SAAS;IACjB,GAAG,EAAE,MAAM,CAAC;IACZ,YAAY,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,EAAE,CAAC,cAAc,CAAC;IACxB,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC1B,SAAS,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,cAAM,oBAAoB;IACxB,OAAO,CAAC,KAAK,CAAgC;IAC7C,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,WAAW,CAAC,CAAiB;gBAEzB,WAAW,EAAE,MAAM;IAI/B,cAAc,CAAC,OAAO,EAAE,EAAE,CAAC,WAAW;IAItC,SAAS,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,EAAE,YAAY,EAAE,MAAM,GAAG,MAAM;IAMlE,OAAO,CACL,GAAG,EAAE,MAAM,EACX,YAAY,EAAE,MAAM,EACpB,IAAI,EAAE,EAAE,CAAC,cAAc,EACvB,UAAU,EAAE,EAAE,CAAC,UAAU;IAgB3B,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS;IAI3C,aAAa,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM;IAO5C,SAAS,CAAC,GAAG,EAAE,MAAM,EAAE,SAAS,EAAE,EAAE,CAAC,IAAI;IAQzC,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,EAAE,CAAC,IAAI,GAAG,SAAS;IAI3C,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO;IAIhC,eAAe,IAAI,MAAM,EAAE;IAkC3B,KAAK;IAIL,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,EAAE;CAK/C;AAID,wBAAgB,mBAAmB,CAAC,WAAW,EAAE,MAAM,GAAG,oBAAoB,CAK7E;AAED,wBAAgB,qBAAqB,SAEpC;AAuGD,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,GAAG,GAAG,GAAG,SAAS,CA4InE;AA+HD,wBAAsB,YAAY,CAChC,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM,EAChB,WAAW,GAAE,MAAsB,GAClC,OAAO,CAAC,MAAM,CAAC,CAuQjB"}
@@ -0,0 +1,3 @@
1
+ export * from "./expand_macros";
2
+ export * from "./macro_executer";
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/macros/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,12 @@
1
+ type MacroFunction = Function & {
2
+ name: string;
3
+ };
4
+ export declare class MacroExecutor {
5
+ private cache;
6
+ getMacro(specifier: string, macroName?: string): MacroFunction;
7
+ private load;
8
+ clearCache(specifier?: string): void;
9
+ }
10
+ export declare function macroExecuter(): MacroExecutor;
11
+ export {};
12
+ //# sourceMappingURL=macro_executer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"macro_executer.d.ts","sourceRoot":"","sources":["../../../src/macros/macro_executer.ts"],"names":[],"mappings":"AAMA,KAAK,aAAa,GAAG,QAAQ,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAGjD,qBAAa,aAAa;IACxB,OAAO,CAAC,KAAK,CAAmC;IAEhD,QAAQ,CAAC,SAAS,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,aAAa;IAsB9D,OAAO,CAAC,IAAI;IA6IZ,UAAU,CAAC,SAAS,CAAC,EAAE,MAAM;CAO9B;AAID,wBAAgB,aAAa,IAAI,aAAa,CAE7C"}
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env node
2
+ import * as store from "./store";
3
+ export { store };
4
+ import * as config from "./config";
5
+ export { config };
6
+ export * from "./config/config";
7
+ import * as macros from "./macros";
8
+ export { macros };
9
+ export * from "./macros/expand_macros";
10
+ import * as plugins from "./plugins";
11
+ export { plugins };
12
+ export * from "./plugins/css";
13
+ //# sourceMappingURL=main.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/main.ts"],"names":[],"mappings":";AAIA,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,KAAK,EAAE,CAAC;AAEjB,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,EAAE,MAAM,EAAE,CAAC;AAElB,cAAc,iBAAiB,CAAC;AAEhC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,EAAE,MAAM,EAAE,CAAC;AAElB,cAAc,wBAAwB,CAAC;AAEvC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,CAAC;AACnB,cAAc,eAAe,CAAC"}
@@ -0,0 +1,25 @@
1
+ type SymbolKind = "class" | "function" | "variable" | "interface" | "type" | "enum" | "namespace" | "unknown";
2
+ interface SymbolInfo {
3
+ name: string;
4
+ kind: SymbolKind;
5
+ decorators?: string[];
6
+ isDefault?: boolean;
7
+ }
8
+ interface ImportInfo {
9
+ sourcePath: string;
10
+ resolvedPath: string | null;
11
+ symbols: SymbolInfo[];
12
+ }
13
+ export interface FileNode {
14
+ filePath: string;
15
+ isTsx: boolean;
16
+ directive: "public" | "interactive" | null;
17
+ imports: ImportInfo[];
18
+ exports: SymbolInfo[];
19
+ }
20
+ export interface DependencyGraph {
21
+ [filePath: string]: FileNode;
22
+ }
23
+ export declare function buildGraph(entryPoints: string[]): DependencyGraph;
24
+ export {};
25
+ //# sourceMappingURL=graph.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"graph.d.ts","sourceRoot":"","sources":["../../../../src/plugins/analyzers/graph.ts"],"names":[],"mappings":"AAKA,KAAK,UAAU,GACX,OAAO,GACP,UAAU,GACV,UAAU,GACV,WAAW,GACX,MAAM,GACN,MAAM,GACN,WAAW,GACX,SAAS,CAAC;AAEd,UAAU,UAAU;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,UAAU,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,UAAU,UAAU;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,OAAO,EAAE,UAAU,EAAE,CAAC;CACvB;AAED,MAAM,WAAW,QAAQ;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,OAAO,CAAC;IACf,SAAS,EAAE,QAAQ,GAAG,aAAa,GAAG,IAAI,CAAC;IAC3C,OAAO,EAAE,UAAU,EAAE,CAAC;IACtB,OAAO,EAAE,UAAU,EAAE,CAAC;CACvB;AAED,MAAM,WAAW,eAAe;IAC9B,CAAC,QAAQ,EAAE,MAAM,GAAG,QAAQ,CAAC;CAC9B;AAyJD,wBAAgB,UAAU,CAAC,WAAW,EAAE,MAAM,EAAE,GAAG,eAAe,CAmGjE"}
@@ -0,0 +1,7 @@
1
+ import { Store } from "@/store";
2
+ import { PluginBuild } from "esbuild";
3
+ export declare function stylePlugin(store: Store): {
4
+ name: string;
5
+ setup(build: PluginBuild): void;
6
+ };
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/plugins/css/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAGtC,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK;;iBAGvB,WAAW;EAiB3B"}
@@ -0,0 +1,2 @@
1
+ export declare function generateController(filePath: string, code: string): string | null;
2
+ //# sourceMappingURL=generate_controller.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate_controller.d.ts","sourceRoot":"","sources":["../../../../src/plugins/generators/generate_controller.ts"],"names":[],"mappings":"AA+BA,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,GACX,MAAM,GAAG,IAAI,CAWf"}
@@ -0,0 +1,2 @@
1
+ export declare function generateRscStub(filePath: string, code: string): string;
2
+ //# sourceMappingURL=generate_rsc.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate_rsc.d.ts","sourceRoot":"","sources":["../../../../src/plugins/generators/generate_rsc.ts"],"names":[],"mappings":"AAoBA,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAUtE"}
@@ -0,0 +1,2 @@
1
+ export declare function generateServerComponent(filePath: string, code: string): string;
2
+ //# sourceMappingURL=generate_server_component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate_server_component.d.ts","sourceRoot":"","sources":["../../../../src/plugins/generators/generate_server_component.ts"],"names":[],"mappings":"AAoBA,wBAAgB,uBAAuB,CACrC,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,GACX,MAAM,CAUR"}
@@ -0,0 +1,2 @@
1
+ export declare function generateServerStub(filePath: string, code: string): string;
2
+ //# sourceMappingURL=tsx_server_stub.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tsx_server_stub.d.ts","sourceRoot":"","sources":["../../../../src/plugins/generators/tsx_server_stub.ts"],"names":[],"mappings":"AAoBA,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CA2EzE"}
@@ -0,0 +1,4 @@
1
+ export * from "./my";
2
+ export * from "./analyzers/graph";
3
+ export * from "./css";
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/plugins/index.ts"],"names":[],"mappings":"AAAA,cAAc,MAAM,CAAC;AACrB,cAAc,mBAAmB,CAAC;AAClC,cAAc,OAAO,CAAC"}
@@ -0,0 +1,10 @@
1
+ import type { Plugin } from "esbuild";
2
+ import { DependencyGraph } from "./analyzers/graph";
3
+ interface MyPluginParams {
4
+ isServerBuild: boolean;
5
+ graph?: DependencyGraph;
6
+ onClientFound: (path: string) => void;
7
+ }
8
+ export declare function useMyPlugin(options: MyPluginParams): Plugin;
9
+ export {};
10
+ //# sourceMappingURL=my.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"my.d.ts","sourceRoot":"","sources":["../../../src/plugins/my.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAA4B,MAAM,SAAS,CAAC;AAMhE,OAAO,EAAE,eAAe,EAAY,MAAM,mBAAmB,CAAC;AAO9D,UAAU,cAAc;IACtB,aAAa,EAAE,OAAO,CAAC;IACvB,KAAK,CAAC,EAAE,eAAe,CAAC;IACxB,aAAa,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACvC;AA6ND,wBAAgB,WAAW,CAAC,OAAO,EAAE,cAAc,GAAG,MAAM,CAmC3D"}
@@ -0,0 +1,11 @@
1
+ import type { PluginObj } from "@babel/core";
2
+ import * as BabelTypes from "@babel/types";
3
+ interface PluginContext {
4
+ types: typeof BabelTypes;
5
+ }
6
+ interface PluginState {
7
+ helpersImported?: boolean;
8
+ }
9
+ export declare function j2d({ types: t }: PluginContext): PluginObj<PluginState>;
10
+ export {};
11
+ //# sourceMappingURL=j2d.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"j2d.d.ts","sourceRoot":"","sources":["../../../../src/plugins/transformers/j2d.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAY,MAAM,aAAa,CAAC;AACvD,OAAO,KAAK,UAAU,MAAM,cAAc,CAAC;AAE3C,UAAU,aAAa;IACrB,KAAK,EAAE,OAAO,UAAU,CAAC;CAC1B;AAED,UAAU,WAAW;IACnB,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAu0BD,wBAAgB,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,aAAa,GAAG,SAAS,CAAC,WAAW,CAAC,CAqKvE"}
@@ -0,0 +1,2 @@
1
+ export * from "./store";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/store/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC"}
@@ -0,0 +1,14 @@
1
+ export declare class Store {
2
+ private static instance;
3
+ private containers;
4
+ private constructor();
5
+ static getInstance(): Store;
6
+ set<T>(key: string, value: T): void;
7
+ get<T>(key: string): T[] | undefined;
8
+ has(key: string): boolean;
9
+ delete(key: string): boolean;
10
+ clear(): void;
11
+ keys(): IterableIterator<string>;
12
+ get size(): number;
13
+ }
14
+ //# sourceMappingURL=store.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"store.d.ts","sourceRoot":"","sources":["../../../src/store/store.ts"],"names":[],"mappings":"AAAA,qBAAa,KAAK;IAChB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAQ;IAC/B,OAAO,CAAC,UAAU,CAAqC;IAEvD,OAAO;WAEO,WAAW,IAAI,KAAK;IAO3B,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,GAAG,IAAI;IAMnC,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,SAAS;IAKpC,GAAG,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO;IAIzB,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO;IAI5B,KAAK,IAAI,IAAI;IAIb,IAAI,IAAI,gBAAgB,CAAC,MAAM,CAAC;IAIvC,IAAW,IAAI,IAAI,MAAM,CAExB;CACF"}
@@ -0,0 +1,4 @@
1
+ export declare function toCamelCase(str: string): string;
2
+ export declare function toPascalCase(str: string): string;
3
+ export declare function toSnakeCase(str: string): string;
4
+ //# sourceMappingURL=cases.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cases.d.ts","sourceRoot":"","sources":["../../../src/utils/cases.ts"],"names":[],"mappings":"AAAA,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAI/C;AAED,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAIhD;AAED,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAE/C"}
@@ -0,0 +1,12 @@
1
+ interface FileEntry {
2
+ name: string;
3
+ content: string;
4
+ }
5
+ export interface DirEntry {
6
+ name?: string;
7
+ files?: FileEntry[];
8
+ dirs?: DirEntry[];
9
+ }
10
+ export declare function createStructure(basePath: string, entry: DirEntry): void;
11
+ export {};
12
+ //# sourceMappingURL=create.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/utils/create.ts"],"names":[],"mappings":"AAGA,UAAU,SAAS;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,QAAQ;IACvB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,SAAS,EAAE,CAAC;IACpB,IAAI,CAAC,EAAE,QAAQ,EAAE,CAAC;CACnB;AAED,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,QAAQ,QAWhE"}
@@ -0,0 +1,3 @@
1
+ export * from "./cases";
2
+ export * from "./create";
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC"}
package/package.json ADDED
@@ -0,0 +1,44 @@
1
+ {
2
+ "name": "@kithinji/pod",
3
+ "version": "1.0.0",
4
+ "description": "",
5
+ "bin": {
6
+ "pod": "./dist/main.js"
7
+ },
8
+ "exports": {
9
+ ".": {
10
+ "node": {
11
+ "import": "./dist/main.js"
12
+ },
13
+ "types": "./dist/types/main.d.ts"
14
+ }
15
+ },
16
+ "scripts": {
17
+ "test": "echo \"Error: no test specified\" && exit 1",
18
+ "build": "node build.js"
19
+ },
20
+ "keywords": [],
21
+ "author": "",
22
+ "license": "ISC",
23
+ "type": "module",
24
+ "dependencies": {
25
+ "@babel/core": "^7.28.5",
26
+ "@babel/plugin-syntax-jsx": "^7.27.1",
27
+ "@swc/core": "^1.15.6",
28
+ "commander": "^14.0.2",
29
+ "esbuild": "^0.27.2",
30
+ "fs-extra": "^11.3.3",
31
+ "js-yaml": "^4.1.1",
32
+ "prompts": "^2.4.2",
33
+ "typescript": "^5.9.3",
34
+ "ws": "^8.18.3"
35
+ },
36
+ "devDependencies": {
37
+ "@types/babel__core": "^7.20.5",
38
+ "@types/fs-extra": "^11.0.4",
39
+ "@types/js-yaml": "^4.0.9",
40
+ "@types/node": "^25.0.3",
41
+ "@types/prompts": "^2.4.9",
42
+ "@types/ws": "^8.18.1"
43
+ }
44
+ }