Comments (4)
Thanks for the suggestion.
the editor allows for TypeScript annotations but the compiler doesn't...
They are indeed two different systems. The editor is currently spawned for each node so its doesn't have any understanding of other nodes, their ports and how they are connected but I agree that having types for props would be helpful.
the editor offers to move the JSDoc types to TypeScript types
I actually never noticed, but that's a default suggestion as the editor parses the code as TypeScript for enhanced experience (even though it is not).
from nodes-io.
the editor offers to move the JSDoc types to TypeScript types
I actually never noticed, but that's a default suggestion as the editor parses the code as TypeScript for enhanced experience (even though it is not).
Since the editor is able to correctly translate JSDoc types to TypeScript types, then maybe it's possible to enable the autocomplete/intellisense features from JSDoc types?
FWIW, VSCode can do exactly that...
from nodes-io.
I see that Nodes is using Monaco for its editor, there seems to have been some discussion around this here, though it's not clear to me where it ended up: microsoft/monaco-editor#203
However, a couple of relevant StackOverflow threads seem to indicate it should work in Monaco from v0.9.0...
https://stackoverflow.com/questions/39694407/adding-javascript-type-hints-for-vscode-monaco-intellisence
https://stackoverflow.com/questions/43037243/provide-type-hints-to-monaco-editor
No luck using @type
either, but again the editor offers to move it to TypeScript and can do so correctly...
from nodes-io.
@dmnsgn just wanted to make sure you saw my comments above, from what I can tell, the monaco-editor in Nodes should be able to provide intellisense from JSDocs. This was added in Monaco 0.9.0, seems it does require some options/config in monaco, see: https://stackoverflow.com/questions/43037243/provide-type-hints-to-monaco-editor/45181853#45181853
from nodes-io.
Related Issues (20)
- Node Logs do not display immediately
- Text input doesn´t works well
- Big Sur 11.1 wont load projects HOT 6
- Same Bug on macOS Big Sur HOT 2
- Svelte support
- External editor support with auto-reloading
- Loading overlays everything
- Bundling Error due to new dependency HOT 1
- Bug : Clicking on parameter toggle node selection
- Editor Freezes while creating Project with double-click
- Bundling Error on new project
- Clean js export? HOT 1
- Better Local Library Support / Code Organisation HOT 1
- Better keyboard less navigation HOT 3
- Bug Report
- create canvas problem HOT 1
- It is not a bug but in the globe demo the earth is spinning backwards. HOT 1
- Globe demo
- hello-world
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nodes-io.