Files
codeql/javascript/ql/test/query-tests/Vue/tst.js
2019-02-06 09:38:00 +01:00

17 lines
359 B
JavaScript

let Vue = require('vue');
new Vue( {
created: () => this, // NOT OK
computed: {
x: () => this, // NOT OK
y: { get: () => this }, // NOT OK
z: { set: () => this } // NOT OK
},
methods: {
arrow: () => this, // NOT OK
nonArrow: function() { this; }, // OK
arrowWithoutThis: () => 42, // OK
arrowWithNestedThis: () => (() => this) // OK
}
});