Skip to content

Instantly share code, notes, and snippets.

@davidwallacejackson
Created August 11, 2016 16:34
Show Gist options
  • Select an option

  • Save davidwallacejackson/2b5cfad372464ebe9d3baafc6bad18f7 to your computer and use it in GitHub Desktop.

Select an option

Save davidwallacejackson/2b5cfad372464ebe9d3baafc6bad18f7 to your computer and use it in GitHub Desktop.
Query Param replace:true bug repro
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle',
queryParams: [{
testParam: {
replace: true
}
}],
testParam: 'foo',
setParamToThis: '',
actions: {
changeTestParam(){
this.set('testParam', this.get('setParamToThis'));
this.set('setParamToThis', '');
}
}
});
<h1>Welcome to {{appName}}</h1>
<br>
<br>
Current value: {{testParam}}<br>
<br>
{{input value=setParamToThis}}
<button {{action 'changeTestParam'}}>Change Param</button>
{{outlet}}
<br>
<br>
{
"version": "0.10.4",
"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.7.0",
"ember-data": "2.7.0",
"ember-template-compiler": "2.7.0"
},
"addons": {}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment