Skip to content

Instantly share code, notes, and snippets.

@GavinJoyce
Created January 25, 2018 11:58
Show Gist options
  • Save GavinJoyce/d64ffa7e42703cc42f1ff829eeb0328c to your computer and use it in GitHub Desktop.
Save GavinJoyce/d64ffa7e42703cc42f1ff829eeb0328c to your computer and use it in GitHub Desktop.
New Twiddle
import Ember from 'ember';
export default Ember.Component.extend({
init() {
this._super(...arguments);
throw 'a little exception';
}
});
import Ember from 'ember';
export default Ember.Controller.extend({
count: 0,
actions: {
increment() {
this.incrementProperty('count');
}
}
});
body {
margin: 12px 16px;
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
font-size: 12pt;
}
.error {
color: red;
}
<p>
A reproduction of <a href="https://github.com/glimmerjs/glimmer-vm/issues/484#issuecomment-359464769">this issue</a>.
</p>
<h3>the count is {{count}}.</h3>
<button onclick={{action 'increment'}}>+</button>
<p>
This component will cause an exception in the vm. Clicking the button above will then result in a <span class='error'>Uncaught Error: a glimmer transaction was begun, but one already exists. You may have a nested transaction</span> error.
</p>
{{my-component}}
your name is: {{data.name}}...
{
"version": "0.13.0",
"EmberENV": {
"FEATURES": {}
},
"options": {
"use_pods": false,
"enable-testing": false
},
"dependencies": {
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js",
"ember": "2.13.0",
"ember-template-compiler": "2.13.0",
"ember-testing": "2.13.0"
},
"addons": {
"ember-data": "2.13.2"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment