Skip to content

Commit

Permalink
update description & swap tag to trustedScriptlet
Browse files Browse the repository at this point in the history
  • Loading branch information
stanislav-atr committed Nov 11, 2022
1 parent 68ea2d8 commit 9d78d55
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion scripts/build-docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ const manageDataFromFiles = () => {
.flat(Infinity);

const scriptletsData = fullData.filter(({ type }) => type === 'scriptlet');
const trustedScriptletsData = fullData.filter(({ type }) => type === 'trustedscriptlet');
const trustedScriptletsData = fullData.filter(({ type }) => type === 'trustedScriptlet');
const redirectsData = fullData.filter(({ type }) => type === 'redirect');

return {
Expand Down
4 changes: 2 additions & 2 deletions scripts/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const getFilesList = (relativeDirPath) => {

/**
* Returns parsed tags data which we use to describe the sources:
* - `@scriptlet`/`@redirect` to describe the type and name of source;
* - `@scriptlet`/'trustedScriptlet'/`@redirect` to describe the type and name of source;
* - `@description` actual description for scriptlet or redirect.
* required comments from file.
* In one file might be comments describing scriptlet and redirect as well.
Expand All @@ -55,7 +55,7 @@ const getDescribingCommentTags = (filePath) => {
}
const [base] = tags;
return base?.type === 'scriptlet'
|| base?.type === 'trustedscriptlet'
|| base?.type === 'trustedScriptlet'
|| base?.type === 'redirect';
});

Expand Down
2 changes: 1 addition & 1 deletion src/scriptlets/trusted-click-element.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {

/* eslint-disable max-len */
/**
* @trustedscriptlet trusted-click-element
* @trustedScriptlet trusted-click-element
*
* @description
* Clicks selected elements in a strict sequence, ordered by selectors passed, and waiting for them to render in the DOM first.
Expand Down
2 changes: 1 addition & 1 deletion src/scriptlets/trusted-replace-fetch-response.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import {

/* eslint-disable max-len */
/**
* @trustedscriptlet trusted-replace-fetch-response
* @trustedScriptlet trusted-replace-fetch-response
*
* @description
* Replaces response text content of `fetch` requests if **all** given parameters match.
Expand Down
2 changes: 1 addition & 1 deletion src/scriptlets/trusted-replace-xhr-response.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {

/* eslint-disable max-len */
/**
* @trustedscriptlet trusted-replace-xhr-response
* @trustedScriptlet trusted-replace-xhr-response
*
* @description
* Replaces response content of `xhr` requests if **all** given parameters match.
Expand Down
2 changes: 1 addition & 1 deletion src/scriptlets/trusted-set-cookie.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {

/* eslint-disable max-len */
/**
* @trustedscriptlet trusted-set-cookie
* @trustedScriptlet trusted-set-cookie
*
* @description
* Sets a cookie with arbitrary name and value, with optional path
Expand Down
2 changes: 1 addition & 1 deletion src/scriptlets/trusted-set-local-storage-item.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {

/* eslint-disable max-len */
/**
* @trustedscriptlet trusted-set-local-storage-item
* @trustedScriptlet trusted-set-local-storage-item
*
* @description
* Adds item with arbitrary key and value to localStorage object, or updates the value of the key if it already exists.
Expand Down

0 comments on commit 9d78d55

Please sign in to comment.