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

Durandal redirect during canActivate

Using durandal 2.1.0 on an ASP.Net MVC project. When a view is accessed I use the canActivate function to indicate whether they can access that view like so: self.canActivate = function () { return http.ajaxRequest("get",…
user1166905
  • 2,612
  • 7
  • 43
  • 75
0
votes
1 answer

Durandal widget does not update value in parent view model

I'm using Durandal with the observable plugin enabled to utilize ES5 getters and setters. I've created a simple widget that takes a value and binds it to a text box: Here's the widget's viewmodel.js: define([], function () { var ctor = function…
Glen Hughes
  • 4,712
  • 2
  • 20
  • 25
0
votes
1 answer

Durandal composing same view in foreach

I have to compose same views in a hierarchy. Parent - Child1 - Child2
0
votes
1 answer

Does Durandal have a native way to trigger an event on a specific instance of a module?

I have a complex situation involving several instances of a couple different modules. For example, I have an input module, form module, and a formSelector module. Selecting a form on the formSelector should populate the form with the correct…
christo8989
  • 6,442
  • 5
  • 37
  • 43
0
votes
1 answer

How use DurandalGrid widget in my Durandal SPA project?

I want to create a SPA with durandalJS and Asp.net Web Api frameworks. I have a viewmodel and a view that is responsible for showing the list of People in a grid Along with paging and custom rows. I used durandal grid…
0
votes
0 answers

Durandal widget needs a mobile view, can I use two views for one viewmodel?

I have a Durandal widget, but now a mobile view is needed, this new view would use the same viewmodel. Would something like the following work: if(mobile) widget.mapKind('myWidget','widgets/myWidget/mobileview','widgets/myWidget/viewmodel') else…
0
votes
1 answer

Is it possible to call a custom-bound widget's methods in Durandal?

I have created and registered a widget in Durandal, so now I am able to use it in other views using this markup:
I would like to call methods on that widget from the parent view model, for…
Matt
  • 3,793
  • 3
  • 24
  • 24
0
votes
1 answer

Durandal child router updating bindings only once

The router that I have created successfully builds a navigation model, but it's missing to update some bindings that need to be updated each time a page is loaded within that childRouter (app.pageTitle, app.pageDescription). Is there some way how to…
Peter G.
  • 7,816
  • 20
  • 80
  • 154
0
votes
1 answer

Durandal Get Started Sample

I've tried following the Get Started example from the Durandal homepage, and just get.. I've refreshed the files from the Starter app / example, and followed the Get Started tutorial once a few weeks ago, and twice again today, and just get the…
cometbill
  • 1,619
  • 7
  • 19
  • 41
0
votes
1 answer

How do you configure pathing in Durandal?

I'm a novice at Durandal but familiar with mvc4. I'm attempting to port an existing application that heavily uses knockout to a SPA framework. I've been able to get the standard View / ViewModel convention working with the information from this…
Bill Shihara
  • 375
  • 7
  • 17
0
votes
1 answer

How to access the previous route from Durandal router

Is there a way to access the previous route/instruction from the Durandal.js router? I know I can do router.navigateBack() to actually navigate back, but I want to know the route that I will navigating back to before I trigger the navigation.
jbgarr
  • 1,378
  • 1
  • 12
  • 23
0
votes
1 answer

Knockout.JS: Bind change event of select to another UI attribute

I'd like to make the following inputs visible only if the database property is selected (on Bootstrap change event). Is there an elegant and effective solution in Knockout JS to do it inside HTML and if not then what would be the JavaScript…
Peter G.
  • 7,816
  • 20
  • 80
  • 154
0
votes
0 answers

how to load but not trigger a viewmodal in durandal?

I would like to load a view manually without navigating to it. so in my code the following: router.navigate(url); loads the view and also activates it and navigate to it. I wan all of these except I don't wanna navigate to it. So I want something…
DalekSupreme
  • 1,493
  • 3
  • 19
  • 32
0
votes
1 answer

Electron - Issue Resolving Electron Modules In Renderer Process

I am having difficulty resolving the electron modules in my web application using Electron v0.32.3 using require. My understanding (although its not very clear in the docs) is that the modules are supposed to be automatically available to require…
ChoptimusPrime
  • 433
  • 7
  • 15
0
votes
1 answer

How to close custom Durandal dialog from viewmodel within that dialog?

I've set up a custom dialog using the example here: Durandal 2.0 custom dialog and it's working fine. My equivalent to "existing view" in that example is my login form, which has the usual username/password/login button. The login button submits the…
TheMook
  • 1,531
  • 4
  • 20
  • 58