Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyntaxError: Named export 'stringifyPosition' not found. after fresh install #5

Open
NatsuDragneelKl opened this issue Apr 18, 2023 · 5 comments

Comments

@NatsuDragneelKl
Copy link

I work with yarn and after running yarn dev i got this error, any idea :(?

`file:///C:/xampp816/htdocs/nuxt3-tailwind-kit-main/.nuxt/dev/index.mjs:30
import { stringifyPosition } from 'file://C:/xampp816/htdocs/nuxt3-tailwind-kit-main/node_modules/unist-util-stringify-position/index.js';
^^^^^^^^^^^^^^^^^
SyntaxError: Named export 'stringifyPosition' not found. The requested module 'file://C:/xampp816/htdocs/nuxt3-tailwind-kit-main/node_modules/unist-util-stringify-position/index.js' is a CommonJS module, which may not support all module.exports as named exports.
CommonJS modules can always be imported via the default export, for example using:

import pkg from 'file://C:/xampp816/htdocs/nuxt3-tailwind-kit-main/node_modules/unist-util-stringify-position/index.js';
const { stringifyPosition } = pkg;

at ModuleJob._instantiate (node:internal/modules/esm/module_job:128:21)
at async ModuleJob.run (node:internal/modules/esm/module_job:194:5)
at async Promise.all (index 0)
at async ESMLoader.import (node:internal/modules/esm/loader:385:24)
at async loadESM (node:internal/process/esm_loader:88:5)
at async handleMainPromise (node:internal/modules/run_main:61:12)`
@gravitano
Copy link
Owner

What version of Node.js are you using?

@jorgec
Copy link

jorgec commented Apr 29, 2023

Running into this same problem, on Node 16.20

@ahmaddzidan
Copy link

pelase try install the package below:

pnpm install unist-util-stringify-position
pnpm install unist-builder

it's solved the problem on my project.

Node: 16.17
Nuxi: 3.5.0
NItro: 2.4.1

@thaikolja
Copy link

thaikolja commented May 28, 2023

This issue also appears:

It must be specified in the configuration file via the 'i18n.config' path.
About deprecated reason, see https://v8.i18n.nuxtjs.org/guide/migrating#change-the-route-key-rules-in-pages-option
About new configuration style, see https://v8.i18n.nuxtjs.org/getting-started/basic-usage#translate-with-vue-i18n

  It must be specified in the configuration file via the 'i18n.config' path.
  About deprecated reason, see https://v8.i18n.nuxtjs.org/guide/migrating#change-the-route-key-rules-in-pages-option
  About new configuration style, see https://v8.i18n.nuxtjs.org/getting-started/basic-usage#translate-with-vue-i18n
  at setup (node_modules/@nuxtjs/i18n/dist/module.mjs:1652:13)
  at async normalizedModule (node_modules/@nuxt/kit/dist/index.mjs:170:17)
  at async installModule (node_modules/@nuxt/kit/dist/index.mjs:440:95)
  at async initNuxt (node_modules/nuxt/dist/index.mjs:2908:7)
  at async loadNuxt (node_modules/nuxt/dist/index.mjs:2969:5)
  at async loadNuxt (node_modules/@nuxt/kit/dist/index.mjs:534:19)
  at async Object.invoke (node_modules/nuxi/dist/chunks/prepare.mjs:31:18)
  at async _main (node_modules/nuxi/dist/cli.mjs:48:20)

error Command failed with exit code 1.```

@gravitano
Copy link
Owner

Hi, can you guys try with pnpm instead?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants