![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Nut is a concise query selector engine that just allows you to do extremely simple queries.
You can pick the minified library or install it with :
jam install nut
bower install nut
npm install nut --save-dev
Hey, the names branch supports name
attributes! Thanks to Crydust ;)
Nut aims to be minimal to have a very tiny footprint and extreme velocity based on the observation that much of CSS requests could be kept as simple as possible since javascript is able to handle a lot of things. It is most of the time faster than querySelectorAll
and then faster than all selector engines. Nut does not implement request caching, to avoid unecessary code additions and performance loss, because the user can easily keep a request and pass it as a context to another request.
Here's it can handle :
#foo
section
.bar p
section #foo .bar p
div, #foo, .bar
And here's it can't :
div *
div#foo div.bar
div > p
div + p
So, all pseudo-classes, attribute selectors and other advanced syntax are not allowed. But, let's dig in it :
// Return an array
nut('#foo');
Of course, queries can have a context :
// Get nodes from the #foo context
nut('.bar p',nut('#foo')[0]);
And that's all you need to know ;)
Nut is compatible with ender and supports some useful syntax.
Selecting nodes, as usually:
$('#foo');
$('.bar p',$('#foo')[0]);
Selecting existing nodes:
var nodes=$('.bar');
$(nodes);
Nut is published under the MIT license.
FAQs
The concise CSS selector engine
We found that nut 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
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.