Security News
The Risks of Misguided Research in Supply Chain Security
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.
@j9t/obsohtml
Advanced tools
ObsoHTML is a Node.js script designed to scan HTML, PHP, Nunjucks, Twig, JavaScript, and TypeScript files for obsolete or proprietary HTML attributes and elements (in scripts, it would catch JSX syntax). It helps you identify and update deprecated HTML code to be more sure to use web standards.
ObsoHTML has inherent limitations and may not find all obsolete attributes and elements. If you run into a problem, please file an issue.
npm i @j9t/obsohtml
(To install ObsoHTML globally, use the -g
flag, as in npm i -g @j9t/obsohtml
.)
The script accepts a folder path as a command line option, which can be specified in both short form (-f
) and long form (--folder
). The folder path can be either absolute or relative.
The script can be run in “verbose” mode by appending -v
or --verbose
to the command. This will show information about files and directories that were skipped.
Use the default directory (user home directory):
npx obsohtml
Specify a folder using an absolute path (easiest and most common use case):
npx obsohtml -f /path/to/folder
Specify a folder using a relative path:
npx obsohtml -f ../path/to/folder
Download or fork the source repository.
As mentioned above, the script accepts a folder (-f
, --folder
) and can be run in “verbose” mode (-v
, --verbose
).
(All commands as run from the root directory of the downloaded repository.)
Use the default directory (user home directory):
node bin/obsohtml.js
Specify a folder using an absolute path (easiest and most common use case):
node bin/obsohtml.js -f /path/to/folder
Specify a folder using a relative path:
node bin/obsohtml.js -f ../path/to/folder
The script will output messages to the console indicating any obsolete attributes or elements found in the scanned files, along with the file paths where they were detected.
This started as an experiment, in which I used AI to produce this little HTML quality helper, its tests, and its documentation. While it’s pretty straightforward, I’m sure to have missed something. Please file an issue or contact me directly if you spot a problem or have a suggestion.
Thanks to @mattbrundage, @FabianBeiner, and @AndrewMac for helping to make ObsoHTML better!
FAQs
Find obsolete HTML elements and attributes
The npm package @j9t/obsohtml receives a total of 58 weekly downloads. As such, @j9t/obsohtml popularity was classified as not popular.
We found that @j9t/obsohtml demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.
Research
Security News
Socket researchers found several malicious npm packages typosquatting Chalk and Chokidar, targeting Node.js developers with kill switches and data theft.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.