@cedarjs/codemods 3.0.0-canary.13498 → 3.0.0-canary.13500

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.
@@ -31,12 +31,17 @@ __export(prettify_exports, {
31
31
  default: () => prettify_default
32
32
  });
33
33
  module.exports = __toCommonJS(prettify_exports);
34
- var import_path = __toESM(require("path"));
34
+ var import_node_fs = __toESM(require("node:fs"));
35
+ var import_node_path = __toESM(require("node:path"));
35
36
  var import_prettier = require("prettier");
36
37
  var import_project_config = require("@cedarjs/project-config");
37
38
  const getPrettierConfig = async () => {
39
+ const basePath = (0, import_project_config.getPaths)().base;
40
+ const prettierConfigCjsPath = import_node_path.default.join(basePath, "prettier.config.cjs");
41
+ const prettierConfigMjsPath = import_node_path.default.join(basePath, "prettier.config.mjs");
42
+ const prettierConfigPath = import_node_fs.default.existsSync(prettierConfigCjsPath) ? prettierConfigCjsPath : prettierConfigMjsPath;
38
43
  try {
39
- const { default: prettierConfig } = await import(`file://${import_path.default.join((0, import_project_config.getPaths)().base, "prettier.config.cjs")}`);
44
+ const { default: prettierConfig } = await import(`file://${prettierConfigPath}`);
40
45
  return prettierConfig;
41
46
  } catch {
42
47
  return void 0;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cedarjs/codemods",
3
- "version": "3.0.0-canary.13498+58aaee54d",
3
+ "version": "3.0.0-canary.13500+3e9a105f3",
4
4
  "description": "Codemods to ease upgrading a CedarJS Project",
5
5
  "repository": {
6
6
  "type": "git",
@@ -30,7 +30,7 @@
30
30
  "@babel/plugin-transform-typescript": "^7.26.8",
31
31
  "@babel/runtime-corejs3": "7.29.0",
32
32
  "@babel/traverse": "7.29.0",
33
- "@cedarjs/project-config": "3.0.0-canary.13498",
33
+ "@cedarjs/project-config": "3.0.0-canary.13500",
34
34
  "@svgr/core": "8.1.0",
35
35
  "@svgr/plugin-jsx": "8.1.0",
36
36
  "@vscode/ripgrep": "1.17.0",
@@ -49,7 +49,7 @@
49
49
  "yargs": "17.7.2"
50
50
  },
51
51
  "devDependencies": {
52
- "@cedarjs/framework-tools": "3.0.0-canary.13498",
52
+ "@cedarjs/framework-tools": "3.0.0-canary.13500",
53
53
  "@types/babel__core": "7.20.5",
54
54
  "@types/jscodeshift": "0.12.0",
55
55
  "@types/yargs": "17.0.35",
@@ -60,5 +60,5 @@
60
60
  "publishConfig": {
61
61
  "access": "public"
62
62
  },
63
- "gitHead": "58aaee54d79a9d1e347f7d240fdf7556cca17668"
63
+ "gitHead": "3e9a105f3562b7796982d3e63e9263ca51b79835"
64
64
  }