dartvs / dartvs Goto Github PK
View Code? Open in Web Editor NEWVisual Studio support for Google's Dart programming language.
Home Page: https://visualstudiogallery.msdn.microsoft.com/69112f14-62d0-40fb-9ccc-03e3534e7121
License: MIT License
Visual Studio support for Google's Dart programming language.
Home Page: https://visualstudiogallery.msdn.microsoft.com/69112f14-62d0-40fb-9ccc-03e3534e7121
License: MIT License
I'm not sure what getOverrides is for in the analysis service yet (maybe code-completion for base class method names?), but we probably want it!
This will likely be faster; but introduces some concurrency issues (will have to queue files up).
Doc comments; functions, classes, etc.
Until we do #53, we should hide the References
folder.
pub get
is equivalent to "nuget package restore". It causes pub to read all of the dependencies from pubspec.yaml
and download any that are missing; and remove any that are no longer referenced.
We should execute pub get
in the project root whenver pubspec.yaml
is saved. This command might take some time (it may download from the web) and also may fail with error messages.
Target VM, Output Type are not relevant.
For some reason the applicableSpan doesn't update properly; so VS keeps triggering the QuickInfoSourceProvider on every mouse twitch, even if it's still within the required area :(
[DanTup: Please comment on this issue if you would like VS 2012 support. It's a pain in the ass; but I might do it if there's enough people wanting it]
Hi Dan,
Thanks for your efforts, such a plugin is very welcome.
At the moment I am unable to install it: it doesn't show up in the Visual Studio Gallery (Extensions and updates), when I search with Dart or DartVS it is not found.
When I doubleclick the vsix download i get the message: Installation Failed, This extension is not installable on any currently installed products. This is strange because I have installed VS 2008, VS2010, VS2010 Express, VS2012, VS2012 Express. What could be the cause of this installation failure ?
Thanks very much,
Ivo
When editing project properties, we should sync with pubspec.yaml (Split from #44).
Pub packages work a bit like NuGet packages in Dart; and live in the packages
folder.
The list of packages is stored in pubspec.yaml
in the dependencies
section. This only lists the packages you directly add; dependencies of dependencies will live in the packages
folder even though they're not in this file.
Currently, the folders inside the packages
folder (one per package) are symlinks back to a "pub cache" (eg. C:\Users\Danny\AppData\Roaming\Pub\Cache
) though this may change in the future.
Additionally, pub creates packages
symlinks as subfolders of many other folders (eg. bin
, web
). This means rendering the entire tree will have a bunch of duplicated folders:
I think it might be best for us to:
packages
folder as the references
folder in the current implementation (so it appears at top, and is "special", allowing for future functionality like a pub package search)pubspec.yaml
vs those that just exist on disk (indirect dependencies)Some sort of wildcard; we don't want to make it complicated for VS and non-VS users to work on the same project.
They are hard coded for the previous location of the repository (DanTup/DartVS).
If you type nonsense at the end of the file; an error shows up in the Errors List, but no squiggle in the editor.
Seems to be caused by the offset/length indicating the character after the end of the file.
(Split this out into separate cases when we know exactly what the analysis service supports).
In lots of places we create subscriptions to the Analysis Service; but we won't correctly tear them down when the related view is removed. I suspect this will be leaking.
Currently, many of the project templates will show errors/warnings, because they have code in them (eg. tests) that use packages that need restoring.
We should execute pub get
as part of the new project creation. Note: it might take some time (downloading from the web) or even fail!
Seems like a bug in the analysis service. Reported to Google.
pub build
has a mode
that can control minification etc.; so might be useful to use for that. Not sure if there would be any options to set though.
Currently anything written to STDERR will throw; but these exceptions are not caught and could cause VS to scream and shout.
When typing Dart docs, it'd be nice if pressing Enter correctly inserted a *_
(where _
is a space character) at the right indent level ready for you to just type the next part of the comment (and also insert the closing */
when the /**
is typed.
The IsDartProject
scanning operation has an enormous performance impact on large projects, even if they do not have any Dart files. Instead of preemptively scanning, it should only treat a project as a Dart project the first time a .dart
file is opened (or via some other mechanism, such as a solution option, etc.).
Although the analysis roots shouldn't be sent; it's wasteful to have the Dart VM running for non-Dart projects.
pub serve
and pub run
are used for launching web and/or command line apps. These are the commands that make most sense to be bound to F5
.
[ ] Allow user to set startup object
[ ] If the "startup item" is set to something in the web
folder, use pub serve
[ ] If the "startup item" is set to an html file in the test
folder, use pub serve test
[ ] If the "startup item" is set to a dart file, then pub run
should be used
[ ] Allow the user to set browser to use for pub serve
, including Dartium user-data-dir
pub serve
pub serve
from the project root (if it is not already running)localhost:8080/
*) with the startup file tagged on the endpub serve
should be run like IIS Express; the process should be kept live, even if the user closes the browser and is not debugging; as the development cycle will involve changing files in VS, alt+tab
ing back to the browser and hitting refresh. Unlike IIS Express, there is no systray icon or any indication for the user that it's running; so we must stop the process on exist/project unload, and seamlessly reuse the process if it's already running and the user hits F5.
pub serve test
This is the same as pub serve
but points at the test
folder; allowing tests to be executed in the browser.
pub run
pub run {path to file}
from the project rootpub run
executes the provided Dart script, but will automatically restore packages, run transformers (etc.) before running. Although we could instead use dart.exe {path to file}
I think using pub
would be more user-friendly, as if the user has opened a project they've cloned from the web, they wouldn't need to remember to run pub get
first.
Currently this only really "works on my machine". Need to decide how to ship the analysis server (most likely a small bootstrapper and exec "pub get" on first run?).
Create classification types for all elements reported by the analyzer (even if the formats are not currently customized from their base definitions).
Add a dart project type would be very usefull
pub build
is for packing up an app ready to deploy. It runs all transformers, which includes converting Dart code into JavaScript so that it can run in standard modern browsers. It delets the build
folder (if exists) and then builds the packaged version there. The build
folder would generally be excluded from source control and instead used as the package for deployment.
Although i's called build
, I don't know if it's close enough to a normal build to be hooked into any build actions in VS; it's more like a "publish".
pub build
would always be executed in the project root.
When selecting a variable (etc.), other uses of it should be highlighted in the editor.
Raised in Issue #7; it's possible the current mechanism only shows if it's pinned. I remember seeing a ForceShowErrors (or similar) method that might force the window to appeareven if it's been "closed".
This seems to be what VS does for C#, and it feels like a good way to handle it.
When typing (eg. a method name), the error window flickers between "1 warning" and 0 warnings". At no points were there "0 warnings" (until you finished typing).
Analysis service is sending an empty set of errors (possible due to the way it does multiple passes):
STDIN: {/*...*/,"method":"analysis.updateContent"}
STDOUT: {"id":"28"}
STDOUT: {"event":"analysis.errors","params":{"file":"M:\\Coding\\Games\\dart_games\\web\\main.dart","errors":[]}}
STDOUT: {"event":"analysis.errors","params":{"file":"M:\\Coding\\Games\\dart_games\\web\\main.dart","errors":[/*...actual errors...*/]}}
We should see if there's a way to suspend handling errors until the last event (which is a superset of all issues).
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.