Questions tagged [durandal-2.0]

A cross-device, cross-platform client framework written in JavaScript and designed to make building and maintaining Single Page Applications (SPAs) faster and easier.

Durandal

A cross-device, cross-platform client framework written in JavaScript and designed to make building and maintaining Single Page Applications (SPAs) faster and easier. Visit the project site.

Features

  • Clean MV* Architecture
  • JS & HTML Modularity
  • Simple App Lifecycle
  • Eventing, Modals, Message Boxes, etc.
  • Navigation & Screen State Management
  • Consistent Async Programming w/ Promises
  • App Bundling and Optimization
  • Use any Backend Technology
  • Built on top of jQuery, Knockout & RequireJS
  • Integrates with popular CSS libraries such as Bootstrap and Foundation
  • Make Your Own Templatable and Bindable Widgets

Browser Support

  • IE 6+
  • Firefox 2+
  • Safari 3.2+
  • Chrome 3+
  • Opera 10+

Dependencies

  • jQuery >= 1.8.0
  • Knockout >= 2.2.1
  • RequireJS >= 2.0.0
284 questions
2
votes
0 answers

jquery dataTables undefined

I am following an example here to create dataTables in a SPA using durandal and knockout js and requirejs. I keep getting an error "Cannot read property 'dataTable' of undefined ". My viewModel looks like so: define(['knockout', 'jqueryData',…
mboko
  • 359
  • 6
  • 16
2
votes
1 answer

Durandal - hide section of page depending on url or route

In my durandal app every page except the home page has a left navbar. This left navbar should be update on refresh, though it should reside on shell.html. The problem is that i'm not being able to hide it properly on the home page. I can use jquery…
Pietro Coelho
  • 1,894
  • 1
  • 26
  • 34
2
votes
1 answer

Keyboard shortcuts and Durandal dialogs

Using Durandal, app.showMessage(message, title); shows a modal dialog with the supplied message and title, and a single primary button OK. All this is styled by Bootstrap. It doesn't seem to respect the keyboard. Clicking the OK button with the…
Peter Wone
  • 17,965
  • 12
  • 82
  • 134
2
votes
2 answers

Durandal constructor function but still want to remember data

Let's say I have the following durandal code: define(['durandal/app', 'plugins/http'], function (app) { var vm = function(){ var self = this; self.myData = ko.observableArray([]); } }; vm.activate = function() { …
neo
  • 2,461
  • 9
  • 42
  • 67
2
votes
1 answer

How to import an object in typescript without tripping intellisense?

I am using typescript with durandal as a proof of concept and honestly they aren't gelling. Most recently I'm trying to troubleshoot the following intellisense error: "Cannot convert typeof calendarServiceImport to ICalendarService" ///
Alwyn
  • 8,079
  • 12
  • 59
  • 107
2
votes
1 answer

Multiple charts rendering on top of each other

I've got some chart data that I load through an AJAX call and display with a modified Chart.js that supports tooltips. It works well for the first call, but when I do subsequent calls by changing date ranges, it draws the new chart data on top of…
2
votes
1 answer

durandal 2.0 navigateBack() causes full page refresh

I am trying to get the router.navigateBack function working correctly using Durandal 2.0.1. I have a viewmodel that can create an entity that we'll call lead. After creating a new lead I want to replace the uri so that it has the edit lead route…
John Gurski
  • 91
  • 2
  • 6
2
votes
1 answer

durandaljs router:navigation:composition-complete firing too soon

My question is: what's the best way to know when a child module has fully loaded and finished composition, so that i can then test the html contents of that module? I'm trying to write some integration tests that run after a route has fully…
Tyler Jones
  • 1,283
  • 4
  • 18
  • 38
2
votes
3 answers

durandaljs - navigate to view on button click

maybe i missed the point of navigating in durandal, but if i want to trigger a view on a button click, how is this done? i'm databinding a button to a click function in the viewmodel. however, when the viewmodel gets loaded, it immediately triggers…
bigerock
  • 713
  • 1
  • 9
  • 29
2
votes
1 answer

Durandal rebind when navigating to same module and view with different data

I have a pair viewmodel/view in my application that it is used for displaying different data. The data that is displayed is generated by some user input and a separate route for each set of data is registered on the router. The problem is that…
Razvan
  • 3,017
  • 1
  • 26
  • 35
2
votes
1 answer

Durandal 2.0 Widget Disposal

How is one supposed to properly dispose of a widget in v2.0? From what I have read this is supposedly done automagically when removed from the DOM, but removing my widget from the DOM using say jQuery.remove() doesn't cause canDeactivate() or…
Robb Vandaveer
  • 1,481
  • 20
  • 25
2
votes
0 answers

jquery draggable revert programmatically

I am currently developing a calendar where activities can be drag&dropped to other days. When an activity is dropped into a different day, I show a custom modal using durandal's dialog plugin. The problem is when an user closes the modal, the…
2
votes
1 answer

Refreshing a KendoUI Grid using OData, Popups and Durandal.js

While I've seen various versions of this kind of error before, I have yet to see one with Durandal involved, which is where I think some of the issues are coming from. I have a KendoUI grid where I display a number of Expenses, and I use a Durandal…
2
votes
1 answer

Durandal View composition: How to update a inner html page instantly when other inner html page sends data?

I'm using DurandalJs 2.0 and KnockoutJs. I have two HTML pages, add.html and show.html with their JS files. I want to display both pages as composition in one index.html page. On the left is show.html and displays added records, on the right is…
IRONMAN
  • 168
  • 1
  • 10
2
votes
2 answers

Durandal: Widget's activate callback not behaving like a regular viewmodel's callback

I have a widget that has a drop down list, that needs to be refreshed every time I go to the view. Is there a callback that I can use in the widget's viewmodel, that is called everytime the widget is used? Something that behaves exactly like a…
dlabarca
  • 119
  • 2
  • 10
1 2
3
18 19