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
0
votes
1 answer

App-wide state with RequireJS

Durandal views are AMD modules. The shell is a special case view, and is also a module. It was my understanding that if I wrote a module to return an object instance then I would get a reference to the same instance in any module that requires it;…
Peter Wone
  • 17,965
  • 12
  • 82
  • 134
0
votes
0 answers

Does Q work in version 2.1

Strange problem with Q and durandal 2.1 When i follow the instructions in Durandal docs and insert system.defer = function (action) { var deferred = Q.defer(); action.call(deferred, deferred); var promise = deferred.promise; …
Piotr Stulinski
  • 9,241
  • 8
  • 31
  • 46
0
votes
1 answer

Can't get multiple viewmodels under master viewmodel work in Durandal.JS

I am working on an application which has DurandalJS 2.0.1. I have written a viewmodel, basically I want to implement a master viewmodel that has multiple viewmodels (e.g. account viewmodel has register and login sub…
Rahul Patil
  • 5,656
  • 6
  • 37
  • 65
0
votes
1 answer

loading momentjs with requirejs causes app to hang

I am trying to require momentjs in my web application. I am using ASP.NET MVC on the server-side, and Durandal on the client-side. requirejs.config({ urlArgs: "bust=" + (new Date()).getTime(), paths: { 'text': '../Scripts/text', 'durandal':…
Nick H
  • 245
  • 2
  • 13
0
votes
1 answer

DurandalJS how to redirect without rendering the page?

Is it possible to navigate to some page by hash and then do some logic and redirect back without rendering new page/module but REFRESH the one, where I was navigating from? Actually what I want is to do some logic and refresh the same page without…
Tomasz Sikora
  • 1,649
  • 3
  • 19
  • 30
0
votes
1 answer

durandal, pass parameters to widget during navigation

i have several singleton views in my SPA, each of these view contain the same widget. When the view is activated i take some parameters from the activate callback and pass it to the widget and it works fine. But if i navigate the second time into…
0
votes
2 answers

Durandal Routing

I want to send parameter with default route in durandal js. { route: '', title: 'Welcome', moduleId: 'viewmodels/welcome', nav: true }, like { route: 'test/:id', moduleId: 'viewmodels/test', nav: true }, But unfortunately I can't do it. I want to…
Midhuna
  • 4,523
  • 4
  • 21
  • 22
0
votes
1 answer

Durandaljs generating sub menu from json

Alright, I am fairly new to durandal. I am really struggling getting trying to accomplish this. Here is what I am trying to do: There is a main navigation that is compromised of an inbox, draft, submitted, etc. Clicking on these, gives the user a…
chuckw87
  • 647
  • 1
  • 6
  • 14
0
votes
1 answer

Durandal 2.0 - Update the value of an observable in the view

I'm new to Durandal, my question has probably a very simple issue. I load a list into a dropdown and the current value on the link which display the dropdown, And the value of the link which display the dropdown is not updated correctly when an…
gab89
  • 125
  • 1
  • 7
0
votes
1 answer

how can i redirect mapUnknownRoutes to a parent

This is what i have i a child routing( from work --> index.js) .map(acceptedTypes).buildNavigationModel().mapUnknownRoutes('code404', 'code404'); how can i redirect it to the parent code404 ? my folder looks like this. App | viewmodels | …
Gildas.Tambo
  • 22,173
  • 7
  • 50
  • 78
0
votes
2 answers

How do you know when Durandal has finished swapping views?

I need to perform an action after switching to a view. The first time you switch to a view 'activate' and then 'compositionComplete' is called. After that only 'activate' is called. It would appear that 'activate' is called before the view has…
user310988
0
votes
1 answer

Loading child routers from database durandal

i trying to create child routes in durandal 2 from my database starterkit without success. Although I succeeded in rendering it with static contents as shown below: define(['plugins/router', 'knockout'], function (router, ko) { var childRouter =…
Jay
  • 321
  • 3
  • 7
  • 19
0
votes
2 answers

Naming modules in require js

I have a durandal project and I'd like to try and improve the way I work with modules in my project. I have a configuration below: requirejs.config({ paths: { 'text': '../Scripts/text', 'durandal': '../Scripts/durandal', …
Captain John
  • 1,859
  • 2
  • 16
  • 30
0
votes
1 answer

durandal externelize the dialog response

I work in durandal project. I using the plugin dialog module. I want to write function that show message to the user and return the dialog result. For example: function isValidFunc() { dialog.show(myHtmlPage).then(function…
user5260143
  • 1,048
  • 2
  • 12
  • 36
0
votes
1 answer

AngularJs inject controller from different domain

I've been using DurandalJs for an application I've developed where I have a core group of functionality (JS, Html files) saved in domain XXX. I have a client app (domain YYY) that uses the JS, Html files from domain XXX. I have DurandalJs set up…
Tom Schreck
  • 5,177
  • 12
  • 68
  • 122