Giter Site home page Giter Site logo

jasonlyu123 / sveltevisualstudio Goto Github PK

View Code? Open in Web Editor NEW
11.0 3.0 1.0 329 KB

A language server protocol client for Visual Studio 2019 and 2022. Power by Svelte Language Server

Home Page: https://marketplace.visualstudio.com/items?itemName=lyu-jason.svelte-vs-2022

License: MIT License

C# 99.87% Batchfile 0.13%
visual-studio lsp-client visual-studio-extension

sveltevisualstudio's People

Contributors

dependabot[bot] avatar jasonlyu123 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

asiedusamuel

sveltevisualstudio's Issues

document VS and lsp

Visual studio's document is sometimes not that great compare to vscode. And some of the official docs are obsolete. It would be great to document the code and point out some useful repo as an example for LSP client in visual studio. It would be useful for future contributions or even those who come here for examples.

Question: VSWorkspaceSettings.json

Using Visual Studio 2022, I've placed VSWorkspaceSettings.json in .vs directory

{
  "svelte.plugin.svelte.format.config.svelteBracketNewLine": false,
  "svelte.plugin.svelte.format.config.printWidth": 160
}

but I'm not seeing the above take effect when I format the .svelte file, this solution has multiple projects in it, am I placing this json file incorrectly?

syntax highlight grammar

Investigate if there is a way to use the grammar bundled by visual studio. If not set up an update script like vscode Or maybe just download it in the runtime or build time.

Error during activating language server

Hi!, I can't use this extension in my computer, when I try to open a Svelte file, Visual studio give me this error: Task Failed - Activating language client Svelte For Visual Studio: Language server failed to initialize during the SendingInitializeRequest Stage.

Any fix?
Thanks

JSON-RPC deserialization exception during initialization

I've recently started getting this error in VS2022 when loading up a project using Svelte:

image

More info from the VS logs.

Newtonsoft.Json.JsonSerializationException: Deserializing JSON-RPC result to type InitializeResult failed with JsonSerializationException: Exception of type 'Newtonsoft.Json.JsonSerializationException' was thrown.
   at StreamJsonRpc.JsonMessageFormatter.JsonRpcResult.GetResult[T]()
   at StreamJsonRpc.JsonRpc.<InvokeCoreAsync>d__143`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.LanguageServer.Client.JsonRpcExtensionMethods.<SendMethodRequestAsync>d__1`2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.LanguageServer.Client.RemoteLanguageClientInstance.<SendInitializeRequestAsync>d__101.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.LanguageServer.Client.RemoteLanguageClientInstance.<InitializeAsync>d__100.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at Microsoft.VisualStudio.LanguageServer.Client.RemoteLanguageClientInstance.<InitializeAsync>d__100.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.Threading.ThreadingTools.<WithCancellationSlow>d__9.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.LanguageServer.Client.RemoteLanguageClientInstance.<ActivateLanguageClientAsync>d__107.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)

My VS version:

Version 17.1.6
VisualStudio.17.Release/17.1.6+32421.90

The Svelte For Visual Studio extension is updated to the latest 1.9.0 version.

Known feature doesn't work on Visual Studio but on VS Code

Feature Reason
Semantic Tokens VS 2019 implementation is non-standard / Supported In VS 2022
Linked Editing VS 2019 implementation is nonstandard / Supported In VS 2022
Document Color and Color Picker VS doesn't support it
Smart Select (Selection Range) VS doesn't support it
Completion Snippet VS doesn't support it
Link and Highlight In Hover Info VS doesn't support markdown in hover
Smart Indentation Unknown
Block Comment Auto Close Unknown / Supported In VS 2022
Update Import Not implemented
Reflect js/ts update without file save Implemented in 1.6.0
Document Highlight (Highlight All Occurrences) VS Code has Word Based Implementation

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.