Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use prototypes #21

Closed
sheppard opened this issue Jul 15, 2014 · 1 comment
Closed

use prototypes #21

sheppard opened this issue Jul 15, 2014 · 1 comment

Comments

@sheppard
Copy link
Member

For example, overwriting ds.save requires a hack:

define(['wq/store'], function(ds) {

var _dsSave = ds.save;
ds.save = function(data, id, callback) {
    // custom code ...
    _dsSave(data, id, callback);
}

});

With prototypes, this could become:

define(['wq/store'], function(ds) {

ds.save = function(data, id, callback) {
    // custom code ...
    ds.prototype.save(data, id, callback);
}

});

See #20.

@sheppard sheppard modified the milestone: Later Sep 12, 2014
@sheppard sheppard modified the milestones: 0.8.0, 1.0 May 6, 2015
@sheppard sheppard modified the milestones: 1.0, Future Mar 4, 2016
@sheppard sheppard modified the milestones: Future, 2.0 Apr 23, 2018
@sheppard
Copy link
Member Author

This is superseded by #105 and the potential to use class instead.

@sheppard sheppard removed this from the 2.0 - Material UI milestone Apr 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant