{"id":18358859,"url":"https://github.com/uppercod/cssthis-object","last_synced_at":"2026-05-05T09:32:56.807Z","repository":{"id":113250677,"uuid":"147772434","full_name":"UpperCod/cssthis-object","owner":"UpperCod","description":"It allows using cssthis based on an object, avoiding the need for cssthis-parse.","archived":false,"fork":false,"pushed_at":"2018-09-08T00:42:49.000Z","size":21,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-24T04:16:19.608Z","etag":null,"topics":["css","css-in-js","preact","react"],"latest_commit_sha":null,"homepage":"https://codesandbox.io/s/lpql5vo6n9","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/UpperCod.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-09-07T04:56:35.000Z","updated_at":"2018-09-08T00:43:19.000Z","dependencies_parsed_at":null,"dependency_job_id":"fca43840-8731-4229-8b6b-2c65aa4fae56","html_url":"https://github.com/UpperCod/cssthis-object","commit_stats":{"total_commits":3,"total_committers":1,"mean_commits":3.0,"dds":0.0,"last_synced_commit":"f4b7214eb29e26720e7fe27b4b4bae8263c23d15"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UpperCod%2Fcssthis-object","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UpperCod%2Fcssthis-object/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UpperCod%2Fcssthis-object/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UpperCod%2Fcssthis-object/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/UpperCod","download_url":"https://codeload.github.com/UpperCod/cssthis-object/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239036196,"owners_count":19571459,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["css","css-in-js","preact","react"],"created_at":"2024-11-05T22:19:44.994Z","updated_at":"2026-05-05T09:32:56.747Z","avatar_url":"https://github.com/UpperCod.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cssthis-object\n\nIt allows using [cssthis](https://github.com/uppercod/cssthis) based on an object, avoiding the need for [cssthis-parse](https://github.com/uppercod/cssthis-parse).\n\n## Installation\n\nBy default cssthis, has a method within the style function, called **parse**, this allows to read the content given to cssthis, before executing the css as a function.\n\n\n```javascript\nimport {style} from \"cssthis\";\nimport transform from \"cssthis-object\";\ntransform(style);\n```\n\nOnce you have done the above you can use objects such as CSS.\n\n## Example\n\n```javascript\nimport { style } from \"cssthis\";\n\nlet Button = style(\"button\")({\n    \":this\": {\n        padding: \".5rem 1rem\",\n        background: \"transparent\",\n        border: \"1px solid black\"\n    },\n    \":this:hover\": {\n        animation: \"hover 1s infinite alternate\"\n    },\n    \"@keyframes hover\": {\n        from: {\n            transform: \"scale(1)\"\n        },\n        to: {\n            transform: \"scale(1.2)\"\n        }\n    }\n});\n```\n\nCssthis-object, does not work with nested styles, for example those inherited from sass.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuppercod%2Fcssthis-object","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuppercod%2Fcssthis-object","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuppercod%2Fcssthis-object/lists"}