Questions tagged [donejs]
17 questions
2
votes
2 answers
CanJS on click outside of component effecting component
I would like to add an event listener in in that reacts to the button.
I am sure this is really simple. I am very new to CanJS and working on…

Marc Godard
- 78
- 6
1
vote
1 answer
Calculated value not being updated correctly using donejs
I have standard donejs project with a component and a model both created using the default generators like this:
donejs add component storyBoard story-board
donejs add supermodel story
I left a sample project here:…

nico
- 144
- 12
1
vote
0 answers
Capture remainder of URL with DoneJS
Basically, what I'm aiming to do is capture the rest of a url in a route and store it into the ViewModel.
In AngularJS, you can do this:
$routeProvider.when('/foo/:page*', { ... });
...and when you access /foo/bar/baz, for example,…

CynicalBusiness
- 127
- 2
- 12
0
votes
0 answers
CanJS - correct way to pass a callback from the viewmodel to the stache file
I have an old CanJS component which is renders a React component, and where now I need to pass a callback.
I found a way to pass the callback but I feel it's not the best way because in some cases it seems that the viewmodel reference is not the…

Ninita
- 1,209
- 2
- 19
- 45
0
votes
1 answer
CanJS - Incorrect list objects type after mapping
If I have this instantiation const someObj = new MyObj({...someParams}) and MyObj is defined this way:
MyObj = DefineMap.extend("MyObj", {
myProp: {
Type: AnotherType.List
}
})
and
AnotherType.List = CanList.extend("AnotherType.List", {
…

Ninita
- 1,209
- 2
- 19
- 45
0
votes
1 answer
jQuery: Make second function wait to execute, until first function is complete
I'm trying to use when and done to make the second function run only after the first one is executed, but it's not working.
What I'm trying to achieve here is:
First I use $("#jobshome").load("jobs/newest-jobs .js-toprow"); to load a div from an…

Matt
- 15
- 9
0
votes
1 answer
DoneJS - Dynamic Loader
In Chat-Demo, there is a syntax where the code (https://donejs.com/Guide.html#switch-between-pages) is split into two blocks: one for to load whenever page='chat', and another for for home.
Those two blocks are very…

KOGUMELO
- 31
- 4
0
votes
1 answer
First try on DoneJS - Chat Demo not working
I'm beggining to try DoneJS, starting with de Chat Demo. After copying the instructions, "home" page shows correctly, but the "Start Chat" button is not working. After some digging, i found this messages on Console: can-log.js:98 16: Unable to find…

KOGUMELO
- 31
- 4
0
votes
0 answers
Global/window assignment or console imports failure
I fail to either set global or window property or require/import within browser console, which makes live testing impossible. I avoid running this code in SSR with platform.isNode condition.

janat08
- 1,725
- 2
- 16
- 27
0
votes
0 answers
Disable SSR in donejs
SSR is a cool donejs feature. But in my current project I have no use of it because I am building a page which gets wrapped in a cordova app only.
{
"name": "abc",
"version": "0.0.0",
"description": "abc.org",
"homepage": "www.abc.org",
…

Oscar
- 59
- 1
- 5
0
votes
1 answer
Console Error in steal.js: "Cannot define property _instanceDefinitions"
Loading a page produces the following error:
steal.js:140 Potentially unhandled rejection [1] TypeError: Cannot define property _instanceDefinitions, object is not extensible
at Function.defineProperty ()
at Object.defineExpando…

Oscar
- 59
- 1
- 5
0
votes
1 answer
Accessing the model in donejs view when passing the parameter from child to parent
From official documentation :
passing model from donejs Child component to Parent component model
I have included search filter component in my homepage component and another product table component which is to be updated when the filters…

jain.saloni91
- 23
- 4
0
votes
1 answer
Deploying a donejs app in nodejs server
I am completely new to donejs and created the donejs app using yeoman, and then created a few components. For deploying the application, I ran "node build" and a dist folder was created, which contained a bundles folder and a steal.production.js…

jain.saloni91
- 23
- 4
0
votes
1 answer
Correctly modeling a MVVM application in donejs
What I did
I created a component in donejs and then created two supermodels contact and email using the following commands:
donejs add component contactComponent contact-component
donejs add supermodel contact
donejs add supermodel email
There's…

nico
- 144
- 12
0
votes
1 answer
Cannot run in production mode
I have a donejs application and its running ok in development mode donejs develop, but when I run it in production mode:
donejs build
donejs deploy (to firebase)
NODE_ENV=production donejs start
it will not start and show an error (see CODE…

nico
- 144
- 12