@danielx/civet 0.7.22 → 0.7.23

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.
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/astro.civet.jsx
29
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\astro.civet.jsx
30
30
  var astro_civet_exports = {};
31
31
  __export(astro_civet_exports, {
32
32
  default: () => astro_civet_default
@@ -1,4 +1,4 @@
1
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/astro.civet.jsx
1
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\astro.civet.jsx
2
2
  import civetUnplugin, {} from "./unplugin.mjs";
3
3
  var astro_civet_default = function(opts = {}) {
4
4
  return {
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/esbuild.civet.jsx
29
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\esbuild.civet.jsx
30
30
  var esbuild_civet_exports = {};
31
31
  __export(esbuild_civet_exports, {
32
32
  default: () => esbuild_civet_default
@@ -1,4 +1,4 @@
1
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/esbuild.civet.jsx
1
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\esbuild.civet.jsx
2
2
  import civetUnplugin from "./unplugin.mjs";
3
3
  var esbuild_civet_default = civetUnplugin.esbuild;
4
4
  export {
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/rollup.civet.jsx
29
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\rollup.civet.jsx
30
30
  var rollup_civet_exports = {};
31
31
  __export(rollup_civet_exports, {
32
32
  default: () => rollup_civet_default
@@ -1,4 +1,4 @@
1
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/rollup.civet.jsx
1
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\rollup.civet.jsx
2
2
  import civetUnplugin from "./unplugin.mjs";
3
3
  var rollup_civet_default = civetUnplugin.rollup;
4
4
  export {
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/unplugin.civet.jsx
29
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\unplugin.civet.jsx
30
30
  var unplugin_civet_exports = {};
31
31
  __export(unplugin_civet_exports, {
32
32
  default: () => unplugin_civet_default,
@@ -46,7 +46,8 @@ var import_os = __toESM(require("os"));
46
46
  // source/unplugin/constants.mjs
47
47
  var DEFAULT_EXTENSIONS = [".mjs", ".js", ".mts", ".ts", ".jsx", ".tsx", ".json"];
48
48
 
49
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/unplugin.civet.jsx
49
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\unplugin.civet.jsx
50
+ var hasProp = {}.constructor.hasOwn;
50
51
  var DiagnosticCategory = {};
51
52
  DiagnosticCategory[DiagnosticCategory["Warning"] = 0] = "Warning";
52
53
  DiagnosticCategory[DiagnosticCategory["Error"] = 1] = "Error";
@@ -468,9 +469,16 @@ var rawPlugin = (options = {}, meta) => {
468
469
  import_path.default.basename(id.replace(/\.[jt]sx$/, "")),
469
470
  import_path.default.basename(id)
470
471
  ));
472
+ const blank = /* @__PURE__ */ Object.create(null);
473
+ for (const key in jsonSourceMap) {
474
+ if (!hasProp(jsonSourceMap, key))
475
+ continue;
476
+ const value = jsonSourceMap[key];
477
+ blank[key] = value;
478
+ }
471
479
  let transformed = {
472
480
  code: compiled.code,
473
- map: jsonSourceMap
481
+ map: blank
474
482
  };
475
483
  if (options.transformOutput) {
476
484
  transformed = await options.transformOutput(transformed.code, id);
@@ -1,4 +1,4 @@
1
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/unplugin.civet.jsx
1
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\unplugin.civet.jsx
2
2
  import { createUnplugin } from "unplugin";
3
3
  import civet, { SourceMap } from "@danielx/civet";
4
4
  import { findInDir, loadConfig } from "@danielx/civet/config";
@@ -14,7 +14,8 @@ import os from "os";
14
14
  // source/unplugin/constants.mjs
15
15
  var DEFAULT_EXTENSIONS = [".mjs", ".js", ".mts", ".ts", ".jsx", ".tsx", ".json"];
16
16
 
17
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/unplugin.civet.jsx
17
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\unplugin.civet.jsx
18
+ var hasProp = {}.constructor.hasOwn;
18
19
  var DiagnosticCategory = {};
19
20
  DiagnosticCategory[DiagnosticCategory["Warning"] = 0] = "Warning";
20
21
  DiagnosticCategory[DiagnosticCategory["Error"] = 1] = "Error";
@@ -436,9 +437,16 @@ var rawPlugin = (options = {}, meta) => {
436
437
  path.basename(id.replace(/\.[jt]sx$/, "")),
437
438
  path.basename(id)
438
439
  ));
440
+ const blank = /* @__PURE__ */ Object.create(null);
441
+ for (const key in jsonSourceMap) {
442
+ if (!hasProp(jsonSourceMap, key))
443
+ continue;
444
+ const value = jsonSourceMap[key];
445
+ blank[key] = value;
446
+ }
439
447
  let transformed = {
440
448
  code: compiled.code,
441
- map: jsonSourceMap
449
+ map: blank
442
450
  };
443
451
  if (options.transformOutput) {
444
452
  transformed = await options.transformOutput(transformed.code, id);
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/vite.civet.jsx
29
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\vite.civet.jsx
30
30
  var vite_civet_exports = {};
31
31
  __export(vite_civet_exports, {
32
32
  default: () => vite_civet_default
@@ -1,4 +1,4 @@
1
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/vite.civet.jsx
1
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\vite.civet.jsx
2
2
  import civetUnplugin from "./unplugin.mjs";
3
3
  var vite_civet_default = civetUnplugin.vite;
4
4
  export {
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/webpack.civet.jsx
29
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\webpack.civet.jsx
30
30
  var webpack_civet_exports = {};
31
31
  __export(webpack_civet_exports, {
32
32
  default: () => webpack_civet_default
@@ -1,4 +1,4 @@
1
- // unplugin-civet:/home/daniel/apps/civet/source/unplugin/webpack.civet.jsx
1
+ // unplugin-civet:C:\Users\edemaine\Projects\Civet\source\unplugin\webpack.civet.jsx
2
2
  import civetUnplugin from "./unplugin.mjs";
3
3
  var webpack_civet_default = civetUnplugin.webpack;
4
4
  export {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@danielx/civet",
3
3
  "type": "commonjs",
4
- "version": "0.7.22",
4
+ "version": "0.7.23",
5
5
  "description": "CoffeeScript style syntax for TypeScript",
6
6
  "main": "dist/main.js",
7
7
  "module": "dist/main.mjs",
@@ -77,9 +77,10 @@
77
77
  "docs:dev": "yarn build && vitepress dev civet.dev",
78
78
  "docs:build": "yarn build && vitepress build civet.dev",
79
79
  "docs:preview": "yarn build && vitepress preview civet.dev",
80
- "prepublishOnly": "yarn build && yarn test",
80
+ "prepublishOnly": "yarn build && yarn test && yarn changelog",
81
81
  "test": "bash ./build/test.sh",
82
- "test:self": "yarn build && mocha --config .mocharc-self.json"
82
+ "test:self": "yarn build && mocha --config .mocharc-self.json",
83
+ "changelog": "civet build/changelog.civet"
83
84
  },
84
85
  "author": "Daniel X. Moore",
85
86
  "license": "MIT",