Dart is a class-based, optionally-typed programming language for building web and command-line applications. Dart compiles to modern JavaScript to run on the client and runs natively on the Dart VM for server-side apps.
6
votes
0answers
80 views
Preserving methods during dart2js minification and tree-shaking
I have a few files that I have written in dart that I want to compile to javascript and include in a few html files that are running in my Android application.
The files consist of a main method, ...
4
votes
0answers
77 views
Dart with Maven (in Spring Boot App)
I like Dart, I have been playing with it for a while. I'd like to integrate with my Maven web app project based on Spring Boot.
I suppose the correct way is to use dart-maven-plugin. But I'm not sure ...
4
votes
0answers
188 views
Creating an angular dart component dynamically
I'm trying to create an angular dart component dynamically. I know it's not a best practice but I have to because of how my angular widgets are being inserted.
I based my work off of:
How to add a ...
4
votes
0answers
125 views
Standalone DartVM: Self-Signed Certificates and SSL
I've been struggling recently with using the standalone DartVM and SSL as a client. I'm of the understanding that Dart uses Mozilla NSS to manage the certificates. What I'm having a problem wit, is ...
4
votes
0answers
142 views
Issue with angular dart module initialization
I recently upgraded angular dart to the recent version [0.13.0]. From then onward it is becoming very difficult just to initialize the application. I have spent around a week fighting with this. I get ...
4
votes
0answers
246 views
How do I `addRules` for the `declarativeContent` API with chrome.dart
I am trying to use the Declarative Content API with chrome.dart. I want to display a pageAction icon only when a matching URL is loaded.
I am looking for an working example how to do this.
What I am ...
4
votes
0answers
153 views
Why native wrapped functions in Dart are such heavyweight in comparison with “DEFINE NATIVE ENTRY” functions that are very lightweight?
I cannot understand: "Why this reassurance?".
This is wrapper for custom native function from dart/runtime/vm/native_entry.cc:
It intended for the Dart programmers that want write native extensions.
...
3
votes
0answers
98 views
Can no longer deploy Dart app to appengine - “Could not start serving the given version”
I can no longer deploy my app to appengine. I've tried several times today and yesterday. It seems to deploy OK but then can't start it.
Seems to be the same as Suddenly Getting and Error When ...
3
votes
0answers
122 views
Missing method “null”. Code generation for the smoke package seems incomplete
I'm using a number of core-ajax-dart elements on a web page. The custom events firing seems to be broken. When using the declarative on-core-response="{{ajaxNewProjectResponse}}" the element seems to ...
3
votes
0answers
57 views
Dart Event Queue: How to debug event queue?
I'm writing some integration tests which utilize an HttpServer, a bunch of Directory().watch()'ers and possibly some other future/stream listening code.
I'm using the following test configuration:
...
3
votes
0answers
205 views
In AngularDart, how should I reference my templates in templateUrl so they work for both Dartium and dart2js?
I currently have this directory layout:
project
web
app.html
main.dart
templates
app.html
alerts.html
menu.html
components
...
3
votes
0answers
61 views
Is it possible to bypass the ShadowDOM polyfill in Dart?
Is it possible to bypass platform.js when using it in dart?
This is an example:
final style = new dom.StyleElement()..text = css;
dom.document.head.append(style);
style.sheet.cssRules; //this ...
3
votes
0answers
135 views
Paper-tabs selection bar randomly visible when individual paper-tab data binded via Angular.dart?
The paper-tab somehow wrongly calculates the width of selection bar to be 0px, possibly due to the data being bound at a later point because of Angular.dart bindings. Is there an event which we can ...
3
votes
0answers
95 views
Angular dart click event on <a> href that is wrapped in shadow dom is retargeted to wrapper
In Angular dart tutorial Chapter_06, the default router is based on hash. After change it to Html 5 push state, the route on edit button which is inside of view_recipe_component does not work.
After ...
3
votes
0answers
99 views
Dart Spectre Model can not be rendered
There was a problem running the Spectre "depth_texture_main.dart" example in Dart version 26274.
I ran the code unmodified from https://github.com/johnmccutchan/spectre.
Chromium message:
The page ...
3
votes
0answers
231 views
The included part ''xclickcounter.dart'' must have a part-of directive
Create a sample web application using the Web UI (web_ui) library, e.g., mylib
open mylib.dart, make it a library:
library mylib;
import 'dart:html';
import 'package:web_ui/web_ui.dart';
part ...
3
votes
0answers
115 views
Is that possible to load templates dynamically in Dartlang WebUI
Is that possible to load templates in Dartlang Web UI dynamically I mean the other way then
<link rel="import" href='otherfile.html'>
3
votes
0answers
243 views
Loading dart file from embedded server
I have created an embedded webserver on a sam3x(with rtos). Just for fun I thought it would be cool to see if I could get dart to run on it as well. My question is how does dartium ask for the .dart ...
2
votes
0answers
36 views
Streaming text in Dart with Redstone/Shelf
It just occurred to me that it would make sense to stream strings, each representing an element from a database query instead of returning the whole list of them at the end of the process, this might ...
2
votes
0answers
54 views
Dart2JS and Enumerators
I'm using enumerators (experimental) in my project. Pub Build (Generate JS) in my Dart Editor does not work due to the enums. In my console, this command:
dart2js file.dart --enable-enum
does work, ...
2
votes
0answers
120 views
go-endpoint Invalid date format and method not found
Hy, I have some problems with the Go endpoints and Dart client library.
I use the Go library https://github.com/crhym3/go-endpoints and the dart generator ...
2
votes
0answers
105 views
Suddenly Getting and Error When Deploying Dart App to GAE
I deployed twice today to different version (web3, and serverclient) and then suddenly I keep getting this error:
Could not start serving the given version.
DEBUG: Received error code [1] while ...
2
votes
0answers
102 views
Changing the Color of a Cesium Geometry Instance in Dart
I am trying to update the color of a Cesium geometry instance. I currently have the code working in javascript but when I convert it to dart, it no longer works. The result when I try to change the ...
2
votes
0answers
288 views
Core-input / Paper-input datalist autocomplete
I'm trying to get my paper-input to have autocompletion with the html5 tag datalist.
this is what I have tried so far with no luck:
<paper-input id="pi" list="dl"></paper-input>
...
2
votes
0answers
127 views
How can I replace an element in AngularDart >= 1.0
Answer seems easy - but it isn't, at least not for me.
Here is a complete sample on GitHub: https://github.com/MikeMitterer/Angular.Accordion
Transpiled to JS: (working sample) ...
2
votes
0answers
61 views
“No getter for 'focusAction'.” exception in Dart
I'm trying to bind a Polymer paper input element to an Angular variable but I get this exception:
No getter for 'focusAction'.
STACKTRACE:
#0 StaticClosureMap.lookupGetter ...
2
votes
0answers
76 views
Access scope created in ng-if
I want to access form's ngModels from controller.
HTML looks like this:
<div ng-if="ctrl.showForm">
<form name="myForm">
<input name="model">
...
2
votes
0answers
56 views
What to do when browser stays in waiting state
I am thying to write a simple dart Angular application.
I frequently find that when I try and test the app using dartium
the raw static page is displayed
the console display
[web] GET ...
2
votes
0answers
73 views
Observable property in css background-image path
I have simple polymer element:
<link rel="import" href="packages/polymer/polymer.html">
<polymer-element name="click-counter">
<template>
<style>
div {
...
2
votes
0answers
46 views
How to convert MediaStream to data in Dart?
Is there a way to convert MediaStream image data into a Matrix type variable without going the canvas-context2d-getImageData() route?
For instance if I want to receive a WebRTC stream on a server ...
2
votes
0answers
95 views
Create object snapshot
I'm tinkering with transformers + "analyzer" pub packages and I want to build a 2 stage transformer.
The stages are:
Build AST for each dart source file.
Generate new sources from the first ...
2
votes
0answers
78 views
how to unwrap underlying event object from event listener argument in dart
i have following dart code:
@override
void attached() {
document.onCopy.listen(_onCopyHandler);
}
void _onCopyHandler(Event event) {
// Here i'd like to access event.clipboardData but it
// ...
2
votes
0answers
192 views
Why context2d.backingStorePixelRatio deprecated?
According to Paul Lewis's article, High DPI Canvas: You need to take into account the context.backingStorePixelRatio to solve blurring issues.
If this property was deprecated, will dart take care of ...
2
votes
0answers
149 views
How do I test an angular dart decorator?
I am trying to unit test an angular dart decorator but cannot pass the component compile phase.
I am trying to follow this example : ...
2
votes
0answers
99 views
Polymer Dart 0.10.0 : “Resource interpreted as Script but transferred with MIME type application/dart” whereas trying to run as Javascript
I have a polymer 0.10+ web app that works in Dartium (Dart VM) and worked until Polymer 0.10.0-pre.12.
When I compile it to JS (Pub Build) and run it as JS under Google Chrome, my polymer (big) ...
2
votes
0answers
146 views
Unittest polymer.dart with karma
The problem is polymer is not loading. Karma has filters for the files it loads, I'm trying load and initialize polymer to be able to test polymer elements with no success (outside the test ...
2
votes
0answers
127 views
Selecting multiple files in a dart based chrome app
I was playing around with Google Dart and chrome apps. I tried to select a single file: No problem here!
The code looks like this and prints the filename.
Future<ChooseEntryResult> res = ...
2
votes
0answers
68 views
Can't get HttpInterceptors to work
I'm probably missing something dumb but I cannot get the HttpInterceptor to work. Based on a couple of examples (x x x) and the API reference I wrote this code that doesn't seem to do anything when a ...
2
votes
0answers
111 views
Incomplete chunks on Heroku with Dart app
I enabled WebSockets support on my Heroku application but last week Heroku updated their platform's routing architecture.
Now I get incomplete chunks in my browser. You can try my app:
...
2
votes
0answers
94 views
AngularDart Element onResize event not linked to window
I'm working on a responsive, full-width layout and I need to do some element processing when the size changes. This has to not be linked to the window, as the size can change without the window size ...
2
votes
0answers
104 views
What is the .precompiled.js file dart2js produces?
There’s a .precompiled.js file along .js and .js.map files the dart2js compiler produces. Compiling the code
void main() {
print('Hello, stranger.');
}
results in identical .js and ...
2
votes
0answers
75 views
Dart - markdown formatting after building to js
I am building a simple blog page where I wish to use markdown as the text format.
I have a working page when running in Dartium but when I compile to js the markdown does not come out properly ...
2
votes
0answers
86 views
dart:web_gl: getAttributeLocation returns -1
A call to getAttributeLocation(program,"aTextureCoords") in my code returns -1
However:
The attribute is active (ie not a duplicate question to
Webgl's getAttribLocation oddly returns -1)
It is ...
2
votes
0answers
120 views
dartlang and dartdap library and connection to active directory
I was looking for a good ldap library for Dart for connecting Microsoft Active Directory. I found dartdap, but I can't seem to get it working. I'm 100% shure that my CN and password is correct, ...
2
votes
0answers
104 views
how to pass named optional parameter defined in dart method to ng-click attribute
I have a method in dart, let's call it showSomething(), which has "named optional parameters"
// the following method is in a model called ctrl.
void showSomething(bool _bool, {var ...
2
votes
0answers
219 views
Jetbrains extension in Dartium doesn't connect to Webstorm
I'm having problem with making the Jetbrains extension in Dartium connect to Webstorm.
In Chrome it works perfectly but not in Dartium.
I have checked the ports....
Anyone had the same experience?
...
2
votes
0answers
432 views
Dart memory leaks and garbage collection
I understand that currently Dart doesn't have an explicit way to remove objects from memory and that objects that are no longer referenced anywhere are removed automatically.
Yet I've been running ...
2
votes
0answers
66 views
dart2js + dart:mirrors - hasReflectedType always returns false?
I've been trying to get some dart:mirrors code to work in javascript and just discovered that the JS method for ClassMirror.hasReflectedType looks like this:
get$hasReflectedType: function() {
...
2
votes
0answers
127 views
How do I convert blob to imagedata?
I want to stream an image to webpage via websocket. the data is in RGBA. how do I change the blog into image data?
this is my current code, it doesn't work and it will be slow. is there a direct way ...
2
votes
0answers
316 views
Dart programatically instantiating Polymer-elements from within .dart script
I'm working on setting up a server-client test app in dart.
Right now the server/client connection is working fine. One of the things I want to do though is add and remove custom elements from the ...