Commit cbf36f6d authored by Florian Müllner's avatar Florian Müllner

lint: Restrict deprecated Lang API

Both Lang.Class and Lang.bind are considered legacy, and the ES5/6
replacements should be used instead.

https://gitlab.gnome.org/GNOME/gjs/merge_requests/272

[skip eslint] as this will change the eslint outcome.
parent 9208b1f7
......@@ -58,6 +58,19 @@
"allow": ["!!"]
}
],
"no-restricted-properties": [
"error",
{
"object": "Lang",
"property": "bind",
"message": "Use arrow notation or Function.prototype.bind()"
},
{
"object": "Lang",
"property": "Class",
"message": "Use ES6 classes"
}
],
"nonblock-statement-body-position": [
"error",
"below"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment