Ember 2.8 introduced a new deprecation to remove the use of contains
for `includes, this codemod will change migrate all such occurrences for you.
npx ember2-x-codemods contains-to-includes path/of/files/ or/some**/*glob.js
# or
yarn global add ember2-x-codemods
ember2-x-codemods contains-to-includes path/of/files/ or/some**/*glob.js
node ./bin/cli.js contains-to-includes path/of/files/ or/some**/*glob.js
Input (array-expression.input.js):
[1,2,3].contains(1);
Output (array-expression.output.js):
[1,2,3].includes(1);
Input (variable.input.js):
let arr = [1,2,3];
arr.contains(1);
Output (variable.output.js):
let arr = [1,2,3];
arr.includes(1);