question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

More specific namespacing for CSS classes?

See original GitHub issue

Right now our widget CSS classes are namespaced as .widget-*. .widget is pretty generic. For example, #2893 showed at least one conflict with another library.

Perhaps we should change the namespace to something like .jw-*, which seems more specific to ‘jupyter widgets’ and less generic than .widget

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:2
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
marimeirelescommented, Feb 16, 2021

@maartenbreddels, I don’t think following BEM now is a good idea because nothing else in ipywidgets does. But seems like a very good name convention. Maybe for a next version @jasongrout ?

0reactions
maartenbreddelscommented, Feb 16, 2021

I’m ok with that, but I thought it was good to put it on our radar.

Read more comments on GitHub >

github_iconTop Results From Across the Web

CSS Namespacing for reusable code | by Richard Oliver Bray
Ever since I came across this namespacing by by Harry Roberts I've been unable to name a class without adding a namespace. It...
Read more >
namespace - CSS: Cascading Style Sheets - MDN Web Docs
The defined namespaces can be used to restrict the universal, type, and attribute selectors to only select elements within that namespace.
Read more >
Writing modular CSS (Part 2) — Namespaces | Zell Liew
Here's an example. Let's say I switched the code above to one with namespaces. The HTML will be completely the same (less a...
Read more >
How to namespace your CSS?
There are no namespaces in CSS. All you do in CSS ends up in global scope. This is by design. This leads to...
Read more >
CSS Practice: Namespaces in Complex Projects
They mean more safety when it comes to. new page elements,; foreign code injections, and; new team members; · they preserve ID and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found