by squeaky-clean · 2y ago · 0 comments
You can modify the code to set the display property as inline-block, but now you need a different show function for every possible display value you want to restore. Or you need to build a layer of state to remember what the original value was and hey you've rewritten the jquery version.
And this is all ignoring that the jquery versions just look so much simpler to remember and are cleaner to read.
```css .hide { display: none important!; } ```
```js function hide(el) { el.classList.add('hide'); } ```