question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`alias-model-in-controller` should support `computed.readOnly`

See original GitHub issue

This currently results in an alias-model-in-controller error but should probably not:

// app/controllers/things.js
export default Ember.Controller.extend({
  things: Ember.computed.readOnly('model');
});

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
michalsnikcommented, May 23, 2017

Released in v3.2.0 🎉

1reaction
ryanrishicommented, May 4, 2017

+1 for this. And computed.reads as well?

Read more comments on GitHub >

github_iconTop Results From Across the Web

readOnly - 4.9 - Ember API Documentation
ComputedProperty : computed property which creates a one way computed property to the original value for property. Where oneWay computed macro provides oneWay ......
Read more >
computed shouldn't return readonly · Issue #201 - GitHub
It should be just Readonly<Ref<T>> so that the "value" isn't writable, but there's no ... It seems to be supported in vue-next though?...
Read more >
The Risks You Take When You Use Ember.computed.oneWay
The readOnly function provides us a healthy reminder about what we should and should not be set in our application. oneWay. The Ember.computed....
Read more >
Should read-only Ember computed properties be marked as ...
How should read-only computed properties (say, of Ember.js Models) be documented as, in YUIdoc? Say I have a simple model: /** * Person...
Read more >
Read-only computed properties returning constants
I really don't know…it's not exactly like the value of pi or UInt8.max will ever change! Is someone from the Swift team available...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found