react-code-locator 0.1.17 → 0.2.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 (60) hide show
  1. package/README.md +89 -266
  2. package/dist/client.cjs +1 -399
  3. package/dist/client.cjs.map +1 -1
  4. package/dist/client.d.cts +1 -1
  5. package/dist/client.d.ts +1 -1
  6. package/dist/client.js +1 -371
  7. package/dist/client.js.map +1 -1
  8. package/dist/esbuild.cjs +29 -7149
  9. package/dist/esbuild.cjs.map +1 -1
  10. package/dist/esbuild.d.cts +1 -1
  11. package/dist/esbuild.d.ts +1 -1
  12. package/dist/esbuild.js +29 -7122
  13. package/dist/esbuild.js.map +1 -1
  14. package/dist/index.cjs +42 -398
  15. package/dist/index.cjs.map +1 -1
  16. package/dist/index.d.cts +6 -0
  17. package/dist/index.d.ts +6 -0
  18. package/dist/index.js +42 -370
  19. package/dist/index.js.map +1 -1
  20. package/dist/swc.cjs +29 -7119
  21. package/dist/swc.cjs.map +1 -1
  22. package/dist/swc.d.cts +1 -1
  23. package/dist/swc.d.ts +1 -1
  24. package/dist/swc.js +29 -7090
  25. package/dist/swc.js.map +1 -1
  26. package/dist/{transform-CXh-m5Ez.d.cts → transform-z2n_1yc5.d.cts} +2 -2
  27. package/dist/{transform-CXh-m5Ez.d.ts → transform-z2n_1yc5.d.ts} +2 -2
  28. package/dist/unplugin.cjs +32 -7135
  29. package/dist/unplugin.cjs.map +1 -1
  30. package/dist/unplugin.d.cts +16 -5
  31. package/dist/unplugin.d.ts +16 -5
  32. package/dist/unplugin.js +32 -7106
  33. package/dist/unplugin.js.map +1 -1
  34. package/dist/webpack.cjs +36 -88
  35. package/dist/webpack.cjs.map +1 -1
  36. package/dist/webpack.d.cts +11 -51
  37. package/dist/webpack.d.ts +11 -51
  38. package/dist/webpack.js +36 -58
  39. package/dist/webpack.js.map +1 -1
  40. package/package.json +10 -34
  41. package/dist/core/transform-cjs.cjs +0 -7014
  42. package/dist/core/webpackPitchLoader-cjs.cjs +0 -7032
  43. package/dist/vite.cjs +0 -7200
  44. package/dist/vite.cjs.map +0 -1
  45. package/dist/vite.d.cts +0 -52
  46. package/dist/vite.d.ts +0 -52
  47. package/dist/vite.js +0 -7169
  48. package/dist/vite.js.map +0 -1
  49. package/dist/webpackLoader.cjs +0 -7115
  50. package/dist/webpackLoader.cjs.map +0 -1
  51. package/dist/webpackLoader.d.cts +0 -15
  52. package/dist/webpackLoader.d.ts +0 -15
  53. package/dist/webpackLoader.js +0 -7092
  54. package/dist/webpackLoader.js.map +0 -1
  55. package/dist/webpackRuntimeEntry.cjs +0 -375
  56. package/dist/webpackRuntimeEntry.cjs.map +0 -1
  57. package/dist/webpackRuntimeEntry.d.cts +0 -2
  58. package/dist/webpackRuntimeEntry.d.ts +0 -2
  59. package/dist/webpackRuntimeEntry.js +0 -373
  60. package/dist/webpackRuntimeEntry.js.map +0 -1
@@ -1,56 +1,16 @@
1
- import { Compiler } from 'webpack';
1
+ import { ReactCodeLocatorOptions } from './unplugin.cjs';
2
+ import './client.cjs';
3
+ import 'esbuild';
4
+ import 'rollup';
5
+ import 'unplugin';
6
+ import './transform-z2n_1yc5.cjs';
7
+ import 'vite';
2
8
 
3
9
  /**
4
10
  * Webpack Plugin for react-code-locator
5
- * CJS-compatible version - no unplugin dependency
6
- *
7
- * Usage:
8
- * ```js
9
- * // webpack.config.js
10
- * const { ReactCodeLocatorPlugin } = require('react-code-locator/webpack');
11
- *
12
- * module.exports = {
13
- * plugins: [
14
- * new ReactCodeLocatorPlugin()
15
- * ]
16
- * };
17
- * ```
11
+ * CJS-compatible re-export from unplugin
18
12
  */
13
+ declare const webpackPlugin: (options?: ReactCodeLocatorOptions | undefined) => WebpackPluginInstance;
14
+ declare const _default: (options?: ReactCodeLocatorOptions | undefined) => WebpackPluginInstance;
19
15
 
20
- interface ReactCodeLocatorWebpackOptions {
21
- /**
22
- * Enable source transform for component definitions
23
- * @default true
24
- */
25
- injectComponentSource?: boolean;
26
- /**
27
- * Enable source transform for JSX call sites
28
- * @default true
29
- */
30
- injectJsxSource?: boolean;
31
- /**
32
- * Project root for relative path calculation
33
- * @default process.cwd()
34
- */
35
- projectRoot?: string;
36
- /**
37
- * Include filter for file paths
38
- * @default /\.[jt]sx$/
39
- */
40
- include?: RegExp | RegExp[];
41
- /**
42
- * Exclude filter for file paths
43
- * @default /node_modules/
44
- */
45
- exclude?: RegExp | RegExp[];
46
- }
47
- declare class ReactCodeLocatorPlugin {
48
- private options;
49
- constructor(options?: ReactCodeLocatorWebpackOptions);
50
- apply(compiler: Compiler): void;
51
- }
52
- declare function createReactCodeLocatorPlugin(options?: ReactCodeLocatorWebpackOptions): ReactCodeLocatorPlugin;
53
-
54
- declare const webpackPlugin: typeof createReactCodeLocatorPlugin;
55
-
56
- export { ReactCodeLocatorPlugin, type ReactCodeLocatorWebpackOptions, createReactCodeLocatorPlugin, ReactCodeLocatorPlugin as default, webpackPlugin };
16
+ export { _default as default, webpackPlugin };
package/dist/webpack.d.ts CHANGED
@@ -1,56 +1,16 @@
1
- import { Compiler } from 'webpack';
1
+ import { ReactCodeLocatorOptions } from './unplugin.js';
2
+ import './client.js';
3
+ import 'esbuild';
4
+ import 'rollup';
5
+ import 'unplugin';
6
+ import './transform-z2n_1yc5.js';
7
+ import 'vite';
2
8
 
3
9
  /**
4
10
  * Webpack Plugin for react-code-locator
5
- * CJS-compatible version - no unplugin dependency
6
- *
7
- * Usage:
8
- * ```js
9
- * // webpack.config.js
10
- * const { ReactCodeLocatorPlugin } = require('react-code-locator/webpack');
11
- *
12
- * module.exports = {
13
- * plugins: [
14
- * new ReactCodeLocatorPlugin()
15
- * ]
16
- * };
17
- * ```
11
+ * CJS-compatible re-export from unplugin
18
12
  */
13
+ declare const webpackPlugin: (options?: ReactCodeLocatorOptions | undefined) => WebpackPluginInstance;
14
+ declare const _default: (options?: ReactCodeLocatorOptions | undefined) => WebpackPluginInstance;
19
15
 
20
- interface ReactCodeLocatorWebpackOptions {
21
- /**
22
- * Enable source transform for component definitions
23
- * @default true
24
- */
25
- injectComponentSource?: boolean;
26
- /**
27
- * Enable source transform for JSX call sites
28
- * @default true
29
- */
30
- injectJsxSource?: boolean;
31
- /**
32
- * Project root for relative path calculation
33
- * @default process.cwd()
34
- */
35
- projectRoot?: string;
36
- /**
37
- * Include filter for file paths
38
- * @default /\.[jt]sx$/
39
- */
40
- include?: RegExp | RegExp[];
41
- /**
42
- * Exclude filter for file paths
43
- * @default /node_modules/
44
- */
45
- exclude?: RegExp | RegExp[];
46
- }
47
- declare class ReactCodeLocatorPlugin {
48
- private options;
49
- constructor(options?: ReactCodeLocatorWebpackOptions);
50
- apply(compiler: Compiler): void;
51
- }
52
- declare function createReactCodeLocatorPlugin(options?: ReactCodeLocatorWebpackOptions): ReactCodeLocatorPlugin;
53
-
54
- declare const webpackPlugin: typeof createReactCodeLocatorPlugin;
55
-
56
- export { ReactCodeLocatorPlugin, type ReactCodeLocatorWebpackOptions, createReactCodeLocatorPlugin, ReactCodeLocatorPlugin as default, webpackPlugin };
16
+ export { _default as default, webpackPlugin };