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

Can't import functions from other scripts #256

Open
Henry-E opened this issue Nov 29, 2024 · 0 comments
Open

Can't import functions from other scripts #256

Henry-E opened this issue Nov 29, 2024 · 0 comments

Comments

@Henry-E
Copy link
Collaborator

Henry-E commented Nov 29, 2024

e.g. import { getProposalInfo, saveProposalInfo } from "./proposal-info"; in a file in the scripts folder.

Trying to import a function from another script gives the error

Relative import paths need explicit file extensions in ECMAScript imports when '--moduleResolution' is 'node16' or 'nodenext'. Did you mean './proposal-info.js'?ts(2835)

Changing from nodenext to bundler doesn't help either because it seems to break other thing nodenext is being used for.

This typescript stuff is super unclear. But trying to note the issue anyway.

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

1 participant