{"id":20072339,"url":"https://github.com/jlozovei/itcss-boilerplate","last_synced_at":"2026-05-12T10:32:40.165Z","repository":{"id":86727797,"uuid":"145649748","full_name":"jlozovei/itcss-boilerplate","owner":"jlozovei","description":"Personal ITCSS boilerplate :rocket:","archived":false,"fork":false,"pushed_at":"2018-08-22T04:14:34.000Z","size":7,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-02T12:18:24.568Z","etag":null,"topics":["boilerplate","css","itcss"],"latest_commit_sha":null,"homepage":"","language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jlozovei.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-08-22T03:14:43.000Z","updated_at":"2018-08-22T04:14:35.000Z","dependencies_parsed_at":"2023-03-04T07:45:53.693Z","dependency_job_id":null,"html_url":"https://github.com/jlozovei/itcss-boilerplate","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jlozovei/itcss-boilerplate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jlozovei%2Fitcss-boilerplate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jlozovei%2Fitcss-boilerplate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jlozovei%2Fitcss-boilerplate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jlozovei%2Fitcss-boilerplate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jlozovei","download_url":"https://codeload.github.com/jlozovei/itcss-boilerplate/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jlozovei%2Fitcss-boilerplate/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32934502,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-12T09:19:52.626Z","status":"ssl_error","status_checked_at":"2026-05-12T09:17:33.438Z","response_time":102,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["boilerplate","css","itcss"],"created_at":"2024-11-13T14:39:36.832Z","updated_at":"2026-05-12T10:32:40.149Z","avatar_url":"https://github.com/jlozovei.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ITCSS boilerplate\n\nA simple ITCSS boilerplate to help you organize and mantain a clean, DRY and awesome CSS code.\n\n\n## ITCSS\n\nITCSS is an awesome CSS methodology that consists, literally, in an inverted triangle within CSS. The highest the specificity of your code, the triangle gets lower.  \nWithin ITCSS, you have a specific structure to follow:\n\n- Settings\n- Tools\n- Generic\n- Base\n- Objects\n- Components\n- Trumps\n\n\n## Structure\n\nTo keep it simple, within this boilerplate I've merged some steps of ITCSS - `Base` + `Objects` and also racked off `Trumps`.\nSo, this is our scenario:\n\n\n#### Settings\n\nEverything within `settings` will not generate CSS code - this part is dedicated to organize your colors, base sizes and random things that can be stored within a variable and will be used along the entire project.  \n\n```scss\n$base_blue: #007bff;\n$base_green: #218838;\n```\n\n\n#### Tools\n\nHere we'll have a little bit of code. In general, I like to keep animations, keyframes, mixins and related stuff within `tools`. Also, it will be a nice place for you to store `extends` rules.  \n\n```css\n@keyframes fadeIn{\n    0%{ opacity: 0; }\n    100%{ opacity: 1; }\n}\n```\n\n\n#### Generic\n\nFrom this point, we'll start to write down our `real CSS`. Here is a good place to keep your `reset` and also  some generic rules - these rules are applied with the `Tags Selectors`, like:\n\n```css\nul{\n    padding-left: 16px;\n    margin-bottom: 24px;\n}\n```\n\nBeyond resets and generic rules, here I like to put some general rules, like classes applied to `body`:  \n\n```css\nbody.fixed{\n    overflow: hidden;\n}\n```\n\n#### Objects\n\nFollowing the OOCSS methodology, here we'll have small pieces of our entire `components` - we can also define as patterns that will be repeated within all the project.  \nA good example we can use here is the `.button` rule:\n\n```css\n.button{\n    display: inline-block;\n    position: relative;\n    text-align: center;\n    cursor: pointer;\n    border: 1px solid transparent;\n}\n```\n\nWe defined above a basic structure/appearance for `.button`elements; but, we haven't defined it in its whole.\n\n\n#### Components\n\nThe largest part and the most specific part of our CSS code, here you will have all sort of components you can imagine - `header`, `footer`, `menu`, `sidebar`, and maybe also `buttons` again:\n\n```css\n/* wrapper element for buttons */\n.button__wrapper{\n    text-align: center;\n    max-width: 80%;\n    margin: 0 auto;\n}\n\n/* primary button */\n.button.button--primary{\n    background-color: #007bff;\n    border-color: #007bff;\n    color: #fff;\n}\n```\n\n\n### index.css\n\nOur main CSS file, it contains only `@import` rules.  \n\nFor a long time I used this template a lot with [Sass](https://sass-lang.com/) and now I'm using with [PostCSS](https://postcss.org/). Also, I use [gulp](http://gulpjs.com/) to create the processing and minifying tasks.\n\n\n## Cool References and Further Reading\n\n- [@ahmadajmi/awesome-itcss](https://github.com/ahmadajmi/awesome-itcss)\n- [An Introduction to OOCSS - Smashing Magazine](https://www.smashingmagazine.com/2011/12/an-introduction-to-object-oriented-css-oocss/)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjlozovei%2Fitcss-boilerplate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjlozovei%2Fitcss-boilerplate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjlozovei%2Fitcss-boilerplate/lists"}