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
failed to build locally #3
Comments
Are you running build from the root directory or from the |
Thanks for ur reply, from the |
Try building from the root directory. |
it's ok, but |
Which |
/packages/unified-latex-util-parse |
sth wrong with my env? node - v14.15.4 |
I am running node 16.14.2 and npm 8.5.1. You might need a newer version of npm for workspaces to work correctly. I believe workspaces were only introduced in npm v7. |
I build succeeded through node 16! |
You should be able to import the |
const latexParser = require('unified-latex/packages/unified-latex-util-parse/dist/index.cjs'); tsconfig.json: /node_modules/unified/index.js:1 SyntaxError: Unexpected token export |
Are you using Typescript? If so, you should be importing the es module, not the CommonJS one. Also, your import statement looks weird. Relative imports start with You can try using |
I found eggjs do not support ESM... thx!~ |
Great. I'm glad it got resolved! |
// unified-latex-util-parse
../unified-latex-util-match/dist/index.d.ts:3:1127 - error TS2307: Cannot find module '../unified-latex-types/dist' or its corresponding type declarations.
3 export declare const anyEnvironment: (node: any) => node is import("../unified-latex-types/dist").Environment, anyMacro: (node: any) => node is import("../unified-latex-types/dist").Macro, anyString: (node: any) => node is import("../unified-latex-types/dist").String, argument: (node: any) => node is import("../unified-latex-types/dist").Argument, blankArgument: (node: any) => boolean, comment: (node: any) => node is import("../unified-latex-types/dist").Comment, environment: (node: any, envName?: string | undefined) => node is import("../unified-latex-types/dist").Environment, group: (node: any) => node is import("../unified-latex-types/dist").Group, macro: (node: any, macroName?: string | undefined) => node is import("../unified-latex-types/dist").Macro, math: (node: any) => node is import("../unified-latex-types/dist").InlineMath | import("../unified-latex-types/dist").DisplayMath, parbreak: (node: any) => node is import("../unified-latex-types/dist").Parbreak, string: (node: any, value?: string | undefined) => node is import("../unified-latex-types/dist").String, whitespace: (node: any) => node is import("../unified-latex-types/dist").Whitespace;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The text was updated successfully, but these errors were encountered: