
Security News
Software Engineering Daily Podcast: Feross on AI, Open Source, and Supply Chain Risk
Socket CEO Feross Aboukhadijeh joins Software Engineering Daily to discuss modern software supply chain attacks and rising AI-driven security risks.
The goal of this project is to contain a shared set of styles and related assets for use on several website properties of The Things Network. It does not enforce a particular CSS preprocessor or build flow and allows us to adopt global styles step by step.
The source stylesheets are in Less because it was the only format that can be automatically converted to SCSS and Stylus.
The docs folder uses dist/scss to demonstrate the styles and is a usage example at the same time. You can view the documentation via GitHub Pages.
Depend on the repository, e.g. via NPM:
npm install --save thethingsnetwork/stylebook
You can also lock in to a certain branch or commit.
Import a stylesheet in the language you use:
@import 'ttn/ttn-variables';
body {
color: $ttn-color-brand;
}
This example assumes you run Sass with
--load-path node_modules/stylebook/dist/scssto not have to give the full path on every import.
There are different strategies for using the stylesheets:
Install Bundler:
$ gem install bundler
Install Ruby dependencies via Bundler:
$ bundle install
Install Node.js and NPM.
Install Node.js dependencies via NPM:
$ npm install
Run convert to update dist with Less, SCSS, Stylus and CSS versions and process docs/src.
$ npm run convert
NOTE: Running
npm installwill overwrite the git pre-commit hook to execute npm run convert & npm run add automagically on every commit so you can ignore step 7.
ttn- so that they do not conflict with other frameworks or custom styles on the site.Both Stylus and Sass support variable defaults. Less does not and promotes lazy loading instead. Because we use Less as source to convert to Sass and Stylus this is an issue. So bin/convert does has replacements to make all variables in Stylus and Sass defaults, except dist/*/ttn/bootstrap-variables so it can use but also override Bootstrap variabls.
To run all tests:
npm install
npm test
To update expected with actual output:
UPDATE=1 npm test
FAQs
Styles for The Things Network websites
We found that stylebook 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
Socket CEO Feross Aboukhadijeh joins Software Engineering Daily to discuss modern software supply chain attacks and rising AI-driven security risks.

Security News
GitHub has revoked npm classic tokens for publishing; maintainers must migrate, but OpenJS warns OIDC trusted publishing still has risky gaps for critical projects.

Security News
Rust’s crates.io team is advancing an RFC to add a Security tab that surfaces RustSec vulnerability and unsoundness advisories directly on crate pages.