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

Components aren't showing up in VSCode #908

Closed
FredrikNoren opened this issue Sep 19, 2023 · 2 comments
Closed

Components aren't showing up in VSCode #908

FredrikNoren opened this issue Sep 19, 2023 · 2 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@FredrikNoren
Copy link
Contributor

Repro:

  1. ambient new test
  2. Open in VSCode
  3. Add this to ambient.toml:
[components]
testy = { type = "Duration" }
  1. Go to main. Add this:
fn test_testy() {
    Entity::new().with(testy(), game_time()).spawn();
}
  1. testy has red squiggly lines under it, but when I press ctrl-. it doesn't show "Import ..." to me, it only shows "Generate testy function"
@FredrikNoren FredrikNoren added the bug Something isn't working label Sep 19, 2023
@FredrikNoren FredrikNoren added this to the 0.3 milestone Sep 19, 2023
@philpax
Copy link
Contributor

philpax commented Sep 22, 2023

Hmm. I suspect that this is due to the proc macro not being built until something uses it, but the only things that can use it are marked with client and server features, and those will only get built once the project is built for the first time.

I don't know if there's anything we can do to fix this per se, but I'll try making new_package build the package once it's created and that should hopefully alleviate it.

@philpax
Copy link
Contributor

philpax commented Sep 22, 2023

Test case seems to work for me after the fix in that commit. Please retest once that lands (it's part of #931) and let me know if that works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants