question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Code completion regression in web-sys?

See original GitHub issue

Hi,

There might be a regression in the latest version of the plugin w.r.t auto-completion of the web-sys crate.

I have to admit I’m not 100% sure it actually worked before (I think it did) as I’m toying with that crate only occasionally and I don’t know how to roll back to an older version of the plugin.

See this video:

https://streamable.com/k5bcw

Environment

  • IntelliJ Rust plugin version: 0.2.118.2171-193 and 0.2.119.3015-193-nightly
  • Rust toolchain version: rustc 1.42.0 (b8cedc004 2020-03-09)
  • IDE name and version: CLion 2019.3.4
  • Operating system: Windows 10

Happens both with Experimental and Default macro engine.

Problem description

  • When I load a small sample project using the web-sys crate like this:
    web-sys = { version = "0.3", features = ["Window", "Document"] }
    
  • And then in src/lib.rs try to access methods of a Document struct
  • There is no auto-completion
  • In addition, the following error is printed on the Event Log:
    21:19	Cargo project update failed:
    		Project directory does not exist
    

Steps to reproduce

See above, or clone this repo (intellij_rust_no_suggestion branch).

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:5
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
Undincommented, Oct 27, 2021

Let’s keep it open until we enable procedural macro support by default. See #6908 as a tracking issue

1reaction
ralfbiedertcommented, Oct 27, 2021

OH GOD IT IS FINALLY HAPPENING.

Erm, what I meant to say is that since the last update auto completion actually works with web_sys:

image

This is absolutely fantastic, thank you so much! I’ll close this ticket now since I’m happy.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Web-sys, IntelliJ, jump to class - Rust Users Forum
The main issue is that web-sys puts everything behind feature ... Does anyone have jump / auto completion working with web_sys classes ?...
Read more >
The `wasm-bindgen` Guide - Rust and WebAssembly
Automatically generating TypeScript bindings for Rust code being consumed by JS. ... Examples of using wasm-bindgen , js-sys , and web-sys.
Read more >
Testing Guide - OWASP Foundation
If the source code for the application is available, it should be given to the security staff to assist them while performing their...
Read more >
Siege - An HTTP/HTTPS stress tester was ... - Ubuntu Manpage
As the developers code improved, siege improved until we ultimately had good java code and a pretty decent regression tool. It was helpful...
Read more >
(PDF) Regression Testing Web Services-based Applications
gression testing technique that retests the modified web sys- ... of regression test cases are either based on manual code analysis or based ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found