[go: up one dir, main page]

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

Add diagnostic for specifying RuntimeLib in default.project.json while compiling as a Package project #2657

Open
osyrisrblx opened this issue Mar 21, 2024 · 0 comments
Labels

Comments

@osyrisrblx
Copy link
Member

Scenario

User accidentally specifies a custom scope in package.json, but wants to compile as a Model project. roblox-ts will infer this as a Package project due to the custom scope and emit local TS = _G[script] for RuntimeLib usage.

The user can workaround this by:

  1. Specifying --type Model in CLI args
  2. Removing custom scope from package.json

I think a diagnostic makes sense here. There's no reason you'd want to compile a Package project and include RuntimeLib.lua in your default.project.json. This would only ever result in either packages accidentally publishing with a RuntimeLib.lua or non-package projects compiling with local TS = _G[script] when they shouldn't.

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

No branches or pull requests

1 participant