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.
complexion-time-map
Advanced tools
Want to see if your tokenizer can be tweaked? This library will provide profiling per time-map.
It extends Complexion and gives you detailed timing about the methods being called for your tokenizer. This way one is able to more easily determine the slowest portions or what gets called the most so you can optimize code.
Install the code using npm
, bower
or possibly just clone the repository. Then, use the library in your JavaScript. There is UMD markup (via FidUmd) that should make this library available under any module system that you prefer to use.
Next, you add this between creating an instance of Complexion and where you add your tokens.
var Complexion = require('complexion');
var instance = new Complexion();
require('complexion-time-map')(instance); // This is it
require('your-library-goes-here')(instance);
instance.tokenize(' ... your text ... ');
instance.timeMap.log();
For more information on what the timeMap
property does, see the time-map project documentation.
If you want to work on this library, you need to check out the repository and run npm install
to get the dependencies.
Tests are always included. Make sure tests cover your changes. To run the current tests, just use npm test
or grunt test
(they will run the same test suite).
This software is licensed under an MIT license with an additional non-advertising clause.
FAQs
Time a JavaScript tokenizer
The npm package complexion-time-map receives a total of 13 weekly downloads. As such, complexion-time-map popularity was classified as not popular.
We found that complexion-time-map demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.