Security News
Cloudflare Adds Security.txt Setup Wizard
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
bti-dom-utils
Advanced tools
This is a small collection of DOM utilities that are used frequently at Beneath the Ink. While some of the methods are similar to jQuery, this library is more focused on text in the DOM and extracting partial content from large documents.
Download the latest version from the release page and use via a script tag. The variable DOMUtils
will be attached to window
.
<script type="text/javascript" src="dom-utils.js"></script>
If using Browserify, you can install via NPM and use with require("bti-dom-utils")
.
$ npm install bti-dom-utils
This library is just a plain object with several methods on it. Here is quick example of usage.
DOMUtils.contains(document, document.body); // true
For quick documentation on each function, please see the inline comments in the source code. These comments are in Doxxo format, so you can also build them for a prettier experience.
npm run build-docs
The DOM utils uses Grunt to build a browserify bundle of the original source found in lib/
. When the command below completes, the compiled source will be saved to dist/
directory.
npm install && grunt
If you don't the Grunt cli tools installed globally, run npm install -g grunt-cli
before running that command.
While still in desperate need of more tests, there are a few Mocha-powered unit tests in the test/
directory. Running the tests is very simple. Make sure there is freshly built copy of the library in the dist/
folder and then open test/index.html
in any browser.
FAQs
A semi-random collection of useful DOM utilities.
The npm package bti-dom-utils receives a total of 5 weekly downloads. As such, bti-dom-utils popularity was classified as not popular.
We found that bti-dom-utils demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 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
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
Security News
The Socket Research team breaks down a malicious npm package targeting the legitimate DOMPurify library. It uses obfuscated code to hide that it is exfiltrating browser and crypto wallet data.
Security News
ENISA’s 2024 report highlights the EU’s top cybersecurity threats, including rising DDoS attacks, ransomware, supply chain vulnerabilities, and weaponized AI.