0.22.2 • Published 3 days ago

@locker/eslint-plugin-locker v0.22.2

Weekly downloads
115
License
SEE LICENSE IN LI...
Repository
github
Last release
3 days ago

@locker/eslint-plugin-locker

Lightning Web Security ESLint rules

Installation

$ yarn add --dev eslint @locker/eslint-plugin-locker

Usage

Add @locker/eslint-plugin-locker to the plugins section of your configuration. Then configure the desired rules in the rules section.

Example of .eslintrc:

{
    "plugins": ["@locker/eslint-plugin-locker"],
    "rules": {
        "@locker/locker/blocked-document-properties": "error",
        "@locker/locker/distorted-document-cookie": "warn"
    }
}

For more details about configuration please refer to the dedicated section in the ESLint documentation: https://eslint.org/docs/user-guide/configuring

Configurations

To choose configuration settings, install the @locker/eslint-config-locker sharable configuration package.

Rules

Lightning Web Security

Rule IDDescriptionFixable Using
@locker/locker/distorted-cachestorage-propertiesdistorted CacheStorage properties
@locker/locker/distorted-cookie-store-blocked-propertiesdisallowed CookieStore properties
@locker/locker/distorted-cookie-store-propertiesdistorted CookieStore properties
@locker/locker/distorted-document-blocked-propertiesdisallow blocked Document properties
@locker/locker/distorted-document-cookiedistorted document.cookie
@locker/locker/distorted-document-domain-setterdistort Document#domain setter
@locker/locker/distorted-document-element-replacechildrendistort {DocumentElement}.prototype.replaceChildren
@locker/locker/distorted-document-exec-commanddistorted document.execCommand
@locker/locker/distorted-element-attach-shadowdistorted Element.prototype.attachShadow
@locker/locker/distorted-element-blocked-propertiesdisallow blocked Element properties
@locker/locker/distorted-element-get-inner-htmldistort Element.prototype.getInnerHTML
@locker/locker/distorted-element-inner-html-setterdistort Element.prototype.innerHTML setter
@locker/locker/distorted-element-insert-adjacent-htmldistort Element.prototype.insertAdjacentHTML
@locker/locker/distorted-element-outer-html-setterdistort Element.prototype.outerHTML setter
@locker/locker/distorted-element-set-attributedistort Element.prototype.setAttribute APIs
@locker/locker/distorted-element-set-htmldistort Element.prototype.setHTML
@locker/locker/distorted-element-shadow-root-getterdistort Element.prototype.shadowRoot getter
@locker/locker/distorted-element-toggle-attributedistort Element.prototype.toggleAttribute
@locker/locker/distorted-html-element-blocked-propertiesdisallow blocked HTMLElement properties
@locker/locker/distorted-html-element-inner-text-setterdistort HTMLElement.prototype.innerText setter
@locker/locker/distorted-html-element-outer-text-setterdistort HTMLElement.prototype.outerText setter
@locker/locker/distorted-html-embed-object-element-blocked-propertiesdisallow blocked HTML{EmbedObject}Element properties
@locker/locker/distorted-html-iframe-element-blocked-propertiesdisallow blocked HTMLIFrameElement properties
@locker/locker/distorted-html-iframe-script-element-src-setterdistort HTML{IFrameScript}Element.prototype.src setter
@locker/locker/distorted-html-link-element-rel-list-setterdistort HTMLLinkElement.prototype.relList setter
@locker/locker/distorted-html-link-element-rel-setterdistort HTMLLinkElement.prototype.rel setter
@locker/locker/distorted-named-node-map-set-named-itemdistorted NamedNodeMap.prototype.setNamedItem
@locker/locker/distorted-navigator-sendbeacondistorted navigator.sendBeacon
@locker/locker/distorted-navigator-service-worker-getterdistorted navigator.serviceWorker getter
@locker/locker/distorted-node-insertbeforedistort Node.prototype.insertBefore
@locker/locker/distorted-node-removechilddistort Node.prototype.removeChild
@locker/locker/distorted-node-replacechilddistort Node.prototype.replaceChild
@locker/locker/distorted-node-text-content-setterdistort Node.prototype.textContent setter
@locker/locker/distorted-range-create-contextual-fragmentdistorted Range.prototype.createContextualFragment
@locker/locker/distorted-range-delete-contentsdistorted Range.prototype.deleteContents
@locker/locker/distorted-range-extract-contentsdistorted Range.prototype.extractContents
@locker/locker/distorted-range-insertnodedistorted Range.prototype.insertNode
@locker/locker/distorted-shared-worker-constructordistorted SharedWorker constructor
@locker/locker/distorted-storage-constructordistorted Storage constructor
@locker/locker/distorted-trusted-type-policy-factory-create-policydistort TrustedTypePolicyFactory.prototype.createPolicy
@locker/locker/distorted-url-create-object-urldistorted URL.createObjectURL
@locker/locker/distorted-window-blocked-propertiesdisallow blocked Window properties
@locker/locker/distorted-window-fetchdistorted window.fetch
@locker/locker/distorted-window-frames-getterdistorted window.frames getter
@locker/locker/distorted-window-length-getterdistorted window.length getter
@locker/locker/distorted-window-onstorage-setterdistorted window.onstorage setter
@locker/locker/distorted-window-set-intervaldistorted window.setInterval
@locker/locker/distorted-window-set-timeoutdistorted window.setTimeout
@locker/locker/distorted-worker-constructordistorted Worker constructor
@locker/locker/distorted-xml-http-request-window-opendistorted {XMLHttpRequestWindow}.prototype.open
@locker/locker/distorted-xsltprocessor-transformtodocumentdistorted XSLTProcessor.prototype.transformToDocument
@locker/locker/distorted-xsltprocessor-transformtofragmentdistorted XSLTProcessor.prototype.transformToFragment
@locker/locker/undefined-document-alldocument.all is undefined
0.22.2

3 days ago

0.22.1

13 days ago

0.21.5

1 month ago

0.21.4

2 months ago

0.20.17

2 months ago

0.20.16

2 months ago

0.21.3

2 months ago

0.20.15

3 months ago

0.21.2

3 months ago

0.21.2-test.0

3 months ago

0.21.1

3 months ago

0.20.13

3 months ago

0.20.12

3 months ago

0.20.11

3 months ago

0.21.0

5 months ago

0.19.17

5 months ago

0.20.10

5 months ago

0.20.9

5 months ago

0.20.1

8 months ago

0.20.0

9 months ago

0.18.24

10 months ago

0.19.11

10 months ago

0.19.12

10 months ago

0.19.13

10 months ago

0.19.14

8 months ago

0.19.15

8 months ago

0.19.16

6 months ago

0.20.8

5 months ago

0.20.7

6 months ago

0.20.6

6 months ago

0.20.5

7 months ago

0.20.4

7 months ago

0.20.3

7 months ago

0.20.2

7 months ago

0.18.23

11 months ago

0.19.9

11 months ago

0.18.22

11 months ago

0.19.10

11 months ago

0.19.8

11 months ago

0.19.3

1 year ago

0.19.4

12 months ago

0.19.5

12 months ago

0.19.6

12 months ago

0.19.7

12 months ago

0.18.21

11 months ago

0.18.20

11 months ago

0.17.23

1 year ago

0.17.25

1 year ago

0.17.24

1 year ago

0.17.27

1 year ago

0.17.26

1 year ago

0.18.9

1 year ago

0.18.4

1 year ago

0.18.5

1 year ago

0.18.6

1 year ago

0.18.7

1 year ago

0.18.8

1 year ago

0.17.29

1 year ago

0.17.28

1 year ago

0.17.30

1 year ago

0.18.11

1 year ago

0.18.10

1 year ago

0.18.13

1 year ago

0.18.12

1 year ago

0.18.15

1 year ago

0.18.14

1 year ago

0.18.17

1 year ago

0.18.16

1 year ago

0.19.0

1 year ago

0.19.1

1 year ago

0.19.2

1 year ago

0.18.19

1 year ago

0.18.18

1 year ago

0.17.18

1 year ago

0.17.17

2 years ago

0.17.19

1 year ago

0.17.21

1 year ago

0.17.20

1 year ago

0.17.22

1 year ago

0.18.1

1 year ago

0.18.2

1 year ago

0.18.3

1 year ago

0.18.0

1 year ago

0.16.30

2 years ago

0.17.7

2 years ago

0.17.8

2 years ago

0.17.9

2 years ago

0.17.10

2 years ago

0.17.12

2 years ago

0.17.11

2 years ago

0.17.14

2 years ago

0.17.13

2 years ago

0.17.16

2 years ago

0.17.15

2 years ago

0.17.9-test.4

2 years ago

0.17.9-test.3

2 years ago

0.17.9-test.0

2 years ago

0.17.9-test.1

2 years ago

0.16.29

2 years ago

0.16.28

2 years ago

0.17.4

2 years ago

0.17.5

2 years ago

0.17.6

2 years ago

0.16.25

2 years ago

0.16.26

2 years ago

0.16.27

2 years ago

0.17.2

2 years ago

0.17.3

2 years ago

0.17.0

2 years ago

0.17.1

2 years ago

0.16.21-test.2

2 years ago

0.16.21-test.1

2 years ago

0.17.1-test.0

2 years ago

0.16.19

2 years ago

0.16.21

2 years ago

0.16.22

2 years ago

0.16.20

2 years ago

0.16.23

2 years ago

0.16.24

2 years ago

0.16.10

2 years ago

0.16.11

2 years ago

0.16.14

2 years ago

0.16.15

2 years ago

0.16.12

2 years ago

0.16.13

2 years ago

0.16.18

2 years ago

0.16.16

2 years ago

0.16.17

2 years ago

0.15.17

2 years ago

0.16.3

2 years ago

0.16.4

2 years ago

0.16.5

2 years ago

0.16.6

2 years ago

0.16.7

2 years ago

0.16.8

2 years ago

0.16.9

2 years ago

0.16.1

2 years ago

0.16.2

2 years ago

0.15.13

2 years ago

0.15.14

2 years ago

0.15.12

2 years ago

0.15.15

2 years ago

0.15.16

2 years ago

0.14.28

2 years ago

0.15.11

2 years ago

0.15.4

2 years ago

0.15.5

2 years ago

0.15.6

2 years ago

0.15.7

2 years ago

0.15.8

2 years ago

0.15.9

2 years ago

0.15.3

2 years ago

0.14.24

2 years ago

0.14.23

2 years ago

0.14.22

2 years ago

0.14.27

2 years ago

0.14.26

2 years ago

0.14.25

2 years ago

0.15.10

2 years ago

0.15.0

2 years ago

0.15.2

2 years ago

0.14.20

2 years ago

0.14.21

2 years ago

0.14.17

3 years ago

0.14.16

3 years ago

0.14.15

3 years ago

0.14.14

3 years ago

0.14.19

3 years ago

0.14.18

3 years ago

0.14.13

3 years ago

0.14.12

3 years ago

0.14.11

3 years ago

0.14.6

3 years ago

0.14.7

3 years ago

0.13.10

3 years ago

0.14.5

3 years ago

0.13.9

3 years ago

0.14.2

3 years ago

0.14.3

3 years ago

0.14.4

3 years ago

0.14.1

3 years ago

0.14.0

3 years ago

0.13.7

3 years ago

0.13.8

3 years ago

0.13.6

3 years ago

0.13.5

3 years ago

0.13.4

3 years ago

0.13.3

3 years ago

0.13.2

3 years ago

0.13.1

3 years ago

0.12.14

3 years ago

0.12.13

3 years ago

0.12.12

3 years ago

0.12.10

3 years ago

0.12.9

3 years ago

0.12.8

3 years ago

0.12.7

3 years ago

0.12.6

3 years ago

0.12.4

3 years ago

0.12.3

3 years ago

0.12.2

3 years ago

0.12.1

3 years ago

0.11.16

4 years ago

0.11.15

4 years ago

0.11.11

4 years ago

0.11.9

4 years ago