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

No intellisense for HTML files with Ivy #936

Closed
prabh-62 opened this issue Oct 9, 2020 · 5 comments
Closed

No intellisense for HTML files with Ivy #936

prabh-62 opened this issue Oct 9, 2020 · 5 comments
Labels
bug ivy Feature / enhancement / bug fix in Ivy

Comments

@prabh-62
Copy link

prabh-62 commented Oct 9, 2020

Describe the bug

Navigate to an HTML file inside an angular project. On hovering over variables, vscode says No Definition found for variable-name
html_definition

To Reproduce

Steps to reproduce the behavior:

  • > npx @angular/cli@11.0.0-next.6 new agency-apps --strict true --createApplication false
  • > cd agency-apps
  • > yarn ng generate application admin-console --routing true --style css
  • Open agency-apps directory in VSCode
  • Add file .vscode/settings.json and enable Ivy
{
  "angular.experimental-ivy": true
}
  • Replace code in projects/admin-console/src/app/app.component.html with
{{ title }}
  • Now close VSCode

  • Next step git clone https://github.com/angular/vscode-ng-language-service.git
  • yarn install after navigating to vscode-ng-language-service directory
  • Open vscode-ng-language-service directory in VSCode
  • Switch to Debug tab and start debugging with Launch Client
  • A new VSCode window opens up
  • Open folder agency-apps
  • Open projects/admin-console/src/app/app.component.html file present in workspace
[Error - 3:25:47 p.m.] No config file for /Users/dev/agency-apps/projects/admin-console/src/app/app.component.html

html_ng

Expected behavior

User should be able to navigate to definition from *.html to corresponding *.ts code

Logs

Please attach two logs:

  1. Console output (Go to toolbar --> View --> Output, and copy the contents)
Debugger listening on ws://127.0.0.1:6009/6a759500-d072-4fb3-a7aa-2f0c4fc390a5
For help, see: https://nodejs.org/en/docs/inspector
[Info  - 3:24:53 p.m.] Angular language server process ID: 30032
[Info  - 3:24:53 p.m.] Using typescript/lib/tsserverlibrary v4.0.2 from /Users/prabh/dev/work/del/vscode-ng-language-service/node_modules/typescript/lib/tsserverlibrary.js
[Info  - 3:24:53 p.m.] Using @angular/language-service/bundles/ivy v10.1.2 from /Users/prabh/dev/work/del/vscode-ng-language-service/server/node_modules/@angular/language-service/bundles/ivy.js
[Info  - 3:24:53 p.m.] Log file: /Users/prabh/Library/Application Support/Code/logs/20201009T144328/exthost10/Angular.ng-template/nglangsvc.log
[Info  - 3:24:53 p.m.] Angular Language Service is running under DEBUG mode
Debugger attached.
[Info  - 3:24:57 p.m.] Enabling language service for /Users/prabh/dev/work/del/agency-apps/tsconfig.json.
[Error - 3:25:47 p.m.] No config file for /Users/prabh/dev/work/del/agency-apps/projects/admin-console/src/app/app.component.html
  1. Log file (Path is printed to the console output at startup)

Screenshots

If applicable, add screenshots to help explain your problem.

Additional context

$ ng version

Angular CLI: 11.0.0-next.6
Node: 14.13.1
OS: darwin x64
Yarn: 1.22.10

Angular: 11.0.0-next.5
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router
Ivy Workspace: Yes

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1100.0-next.6
@angular-devkit/build-angular   0.1100.0-next.6
@angular-devkit/core            11.0.0-next.6
@angular-devkit/schematics      11.0.0-next.6
@angular/cli                    11.0.0-next.6
@schematics/angular             11.0.0-next.6
@schematics/update              0.1100.0-next.6
rxjs                            6.6.3
typescript                      4.0.3
@prabh-62 prabh-62 added the bug label Oct 9, 2020
@Hx2heng
Copy link

Hx2heng commented Oct 14, 2020

Configuration "angular.experimental-ivy" is not contain at latest version,maybe we should wait?

@prabh-62
Copy link
Author

Tried with the released version of VS Code extension and Go to Definition works for HTML files inside angular v11 workspace.

  • > code --list-extensions --show-versions
    Angular.ng-template@0.1001.0
> npx @angular/cli@11.0.0-next.7 new agency-apps --create-application=false --strict
> cd agency-apps
> yarn ng g app support-panel --defaults true

intellisense

Issue occurs only when enabling Ivy for VSCode extension

@kyliau kyliau added the ivy Feature / enhancement / bug fix in Ivy label Nov 4, 2020
@kyliau
Copy link
Contributor

kyliau commented Nov 4, 2020

Hi @prabh-62 thanks for trying out the Ivy language service even before it's released!
Indeed, Ivy will remain an experimental feature in v11.0.x
As you know, the backend is now completely powered by the Ivy compiler, and as a result ngcc has to be run before the Ivy compiler could analyze the project.
A big part of our work right now is to automate ngcc so that it'll automatically run when an Angular project is opened.
In the meantime, you'll have to run it manually - it's probably the reason intellisense didn't work for you.

@kyliau
Copy link
Contributor

kyliau commented Nov 13, 2020

We will mark this as closed for now, since we are not ready to provide user support for Ivy Language Service at the moment.

@kyliau kyliau closed this as completed Nov 13, 2020
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Dec 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug ivy Feature / enhancement / bug fix in Ivy
Projects
None yet
Development

No branches or pull requests

3 participants