Issue Given a year, return the century it is in. The first century spans from the year 1 up to and including the year 100, the second – from the year 101 up to and including the year 200, etc.
Continue readingTag: dart-polymer
Print the second largest number on the list using dart
Issue I need to print the second largest number on the list, the output from the below code is all elements in the list except the first and the last one. What is the mistake? void main () { List
Continue readinghow to make widget scale up when it selected in Flutter
Issue I have an app that has pageView.builder and it contains 5 stack widget how can I scale up the widget that user-selected, for example: if the user scrolls to widget 3, widgets 1 & 2 become smaller than widget
Continue readingHow do I get notified when something is added or removed from an observable list in Dart?
Issue I have an observable list from Polymer and Dart. I want a getter to run when something is added or removed from the list. How do I do that? My list: final ObservableList masterList = toObservable([]); My getter: List
Continue readingCORS related errors when getting Channel API client script
Issue I’m currently experimenting with a Google App Engine/Go + Polymer.dart website at http://xclamm.appspot.com/. The problem is that I get the following error when I access http://xclamm.appspot.com/ with Dartium (31.0.1612.0 Developer Build 219647). XMLHttpRequest cannot load https://talkgadget.google.com/talkgadget/channel.js. No ‘Access-Control-Allow-Origin’ header
Continue readingHow do you dispatch and listen for custom events in Polymer?
Issue I want a child element to dispatch a custom event and the parent element to listen for it, and take some action. How do I do this when working with Polymer? Solution You can dispatch a custom event from
Continue readingHow do you import a custom polymer element from within a custom element?
Issue I want to create a custom polymer element that incorporates custom elements from a third party library. My customelement.html file has this in the head section <head> <title>orderlist</title> <link rel=”import” href=”packages/widget/components/accordion.html”> <link rel=”import” href=”packages/widget/components/collapse.html”> </head> All is well, the
Continue readingDart Polymer application as component?
Issue The docs at https://www.dartlang.org/polymer-dart/upgrading-to-polymer-from-web-ui.html state the following: We recommend creating a component for your “application” HTML page. Polymer believes that everything is a component. What exactly does this mean? Is the complete index HTML page a component that is
Continue readingSetting hardcoded value in bound attribute
Issue I have a component with a “label” attribute and since this label will not change, I want to specify it when I declare the component: <parking-list label=”PARKINGS” parkings=”{{parkings}}” on-showparking=”parkingList_showParkingHandler”></parking-list> <parking-list label=”SHOP AND GO” parkings=”{{shopAndGoParkings}}” on-showparking=”parkingList_showParkingHandler”></parking-list> The label value is
Continue readingIs there an event that fires after the DOM is updated as the result of an observed property?
Issue Is there an event that gets fired after the DOM is updated as the result of an observed property being changed? Specifically, I need to alter the scrollTop property of a container to show new content as it’s added.
Continue reading