
Security News
PEP 810 Proposes Explicit Lazy Imports for Python 3.15
An opt-in lazy import keyword aims to speed up Python startups, especially CLIs, without the ecosystem-wide risks that sank PEP 690.
This tool generates browser-specific CSS, stripping unsupported features.
Supported features are:
-webkit-
s_
and *
hacks in IE67, remove in all other browsers;;
(result of stripping things)More to come:
Because CSS is on the critical path to rendering pages. It must be small! Or else!
Why send extra bytes the browser has no use for? Walk in Firefox's shoes for a minute. You've just served something like:
a {
filter: progid:microsoft:obladi:oblada:AlphaImageLoader(bananas.png);
}
You can imagine Firefox thinking: "This is BS... I mean ... too browser-specific! I've no use for this. And I don't appreciate you wasting my time. I could've been delighting your users with your gorgeous app and instead look at me - having to sift through this nonsense"
$ npm install bscss
The list of supported browsers is as follows:
var bs = require('bscss');
var css =
'a{color: red; _color: blue; -o-stuff: cool; -ms-filter: 1}';
css = bs.transform(css, 'chrome');
This spits out only the color: red
, the rest is stripped.
bs.transform(css, 'ie7');
for example will keep the color:blue
too and remove the -
-prefixed properties.
In IE6 and IE7 the hack characters are removed, e.g. _color
becomes color
Available at http://bscss.csspatterns.com
FAQs
Browser-specific CSS
We found that bscss 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
An opt-in lazy import keyword aims to speed up Python startups, especially CLIs, without the ecosystem-wide risks that sank PEP 690.
Security News
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
Security News
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.