@cedarjs/cli 3.0.0-canary.13193 → 3.0.0-canary.13196

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 (2) hide show
  1. package/dist/lib/index.js +5 -2
  2. package/package.json +11 -11
package/dist/lib/index.js CHANGED
@@ -36,7 +36,7 @@ const nameVariants = (name) => {
36
36
  pluralConstantName: decamelize(pluralize(normalizedName)).toUpperCase()
37
37
  };
38
38
  };
39
- const generateTemplate = async (templateFilename, { name, ...rest }) => {
39
+ const generateTemplate = (templateFilename, { name, ...rest }) => {
40
40
  try {
41
41
  const templateFn = template(readFile(templateFilename).toString());
42
42
  const renderedTemplate = templateFn({
@@ -157,7 +157,10 @@ const getConfig = () => {
157
157
  };
158
158
  const getPrettierOptions = async () => {
159
159
  try {
160
- const { default: prettierOptions } = await import(`file://${path.join(getPaths().base, "prettier.config.cjs")}`);
160
+ const cjsPath = path.join(getPaths().base, "prettier.config.cjs");
161
+ const mjsPath = path.join(getPaths().base, "prettier.config.mjs");
162
+ const prettierConfigPath = fs.existsSync(cjsPath) ? cjsPath : mjsPath;
163
+ const { default: prettierOptions } = await import(`file://${prettierConfigPath}`);
161
164
  return prettierOptions;
162
165
  } catch (e) {
163
166
  if (process.env.VITEST_POOL_ID !== void 0) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cedarjs/cli",
3
- "version": "3.0.0-canary.13193+09993977b",
3
+ "version": "3.0.0-canary.13196+4267251f5",
4
4
  "description": "The CedarJS Command Line",
5
5
  "repository": {
6
6
  "type": "git",
@@ -33,15 +33,15 @@
33
33
  "dependencies": {
34
34
  "@babel/preset-typescript": "7.28.5",
35
35
  "@babel/runtime-corejs3": "7.28.4",
36
- "@cedarjs/api-server": "3.0.0-canary.13193",
37
- "@cedarjs/cli-helpers": "3.0.0-canary.13193",
38
- "@cedarjs/fastify-web": "3.0.0-canary.13193",
39
- "@cedarjs/internal": "3.0.0-canary.13193",
40
- "@cedarjs/prerender": "3.0.0-canary.13193",
41
- "@cedarjs/project-config": "3.0.0-canary.13193",
42
- "@cedarjs/structure": "3.0.0-canary.13193",
43
- "@cedarjs/telemetry": "3.0.0-canary.13193",
44
- "@cedarjs/web-server": "3.0.0-canary.13193",
36
+ "@cedarjs/api-server": "3.0.0-canary.13196",
37
+ "@cedarjs/cli-helpers": "3.0.0-canary.13196",
38
+ "@cedarjs/fastify-web": "3.0.0-canary.13196",
39
+ "@cedarjs/internal": "3.0.0-canary.13196",
40
+ "@cedarjs/prerender": "3.0.0-canary.13196",
41
+ "@cedarjs/project-config": "3.0.0-canary.13196",
42
+ "@cedarjs/structure": "3.0.0-canary.13196",
43
+ "@cedarjs/telemetry": "3.0.0-canary.13196",
44
+ "@cedarjs/web-server": "3.0.0-canary.13196",
45
45
  "@listr2/prompt-adapter-enquirer": "2.0.16",
46
46
  "@opentelemetry/api": "1.8.0",
47
47
  "@opentelemetry/core": "1.22.0",
@@ -103,5 +103,5 @@
103
103
  "publishConfig": {
104
104
  "access": "public"
105
105
  },
106
- "gitHead": "09993977b1b000df721707d7057ab120fd7b8022"
106
+ "gitHead": "4267251f540a06a4619f84cfe912d42fa8b017d7"
107
107
  }