Skip to content

Commit

Permalink
Enable the ESLint no-var rule in the src/shared/ folder
Browse files Browse the repository at this point in the history
Previously this rule has been enabled in the `web/` folder, and in select files in the `src/` sub-folders.
In this case, enabling of this rule didn't actually require any further code changes.

Please find additional details about the ESLint rule at https://eslint.org/docs/rules/no-var
  • Loading branch information
Snuffleupagus committed Oct 2, 2020
1 parent 88f72d6 commit 199ab75
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 3 deletions.
10 changes: 10 additions & 0 deletions src/shared/.eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"extends": [
"../../.eslintrc"
],

"rules": {
// ECMAScript 6
"no-var": "error",
},
}
1 change: 1 addition & 0 deletions src/shared/cffStandardStrings.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */

'use strict';

Expand Down
1 change: 0 additions & 1 deletion src/shared/compatibility.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */

import { isNodeJS } from "./is_node.js";

Expand Down
1 change: 1 addition & 0 deletions src/shared/fonts_utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
/* globals CFFDictDataMap, CFFDictPrivateDataMap, CFFEncodingMap, CFFStrings,
Components, Dict, dump, FormatError, isNum, netscape, Stream */

Expand Down
1 change: 0 additions & 1 deletion src/shared/message_handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error, prefer-const: error */

import {
AbortException,
Expand Down
1 change: 0 additions & 1 deletion src/shared/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */

import "./compatibility.js";

Expand Down

0 comments on commit 199ab75

Please sign in to comment.