{"id":13480448,"url":"https://github.com/muhajirdev/gatsby-plugin-tailwindcss","last_synced_at":"2025-09-07T05:33:15.807Z","repository":{"id":48029730,"uuid":"151690970","full_name":"muhajirdev/gatsby-plugin-tailwindcss","owner":"muhajirdev","description":"Plug Tailwind CSS to your Gatsby website","archived":false,"fork":false,"pushed_at":"2023-12-15T02:25:57.000Z","size":187,"stargazers_count":46,"open_issues_count":11,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-31T08:53:17.720Z","etag":null,"topics":["emotion","gatsby","gatsby-plugin","react","tailwind-css"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/gatsby-plugin-tailwindcss","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/muhajirdev.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}},"created_at":"2018-10-05T08:19:56.000Z","updated_at":"2024-03-19T10:22:04.000Z","dependencies_parsed_at":"2024-01-18T21:40:21.879Z","dependency_job_id":"452c42ff-de51-49af-89be-da6ac16bf9e4","html_url":"https://github.com/muhajirdev/gatsby-plugin-tailwindcss","commit_stats":null,"previous_names":["muhajirframe/gatsby-plugin-tailwindcss"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/muhajirdev/gatsby-plugin-tailwindcss","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhajirdev%2Fgatsby-plugin-tailwindcss","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhajirdev%2Fgatsby-plugin-tailwindcss/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhajirdev%2Fgatsby-plugin-tailwindcss/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhajirdev%2Fgatsby-plugin-tailwindcss/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/muhajirdev","download_url":"https://codeload.github.com/muhajirdev/gatsby-plugin-tailwindcss/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhajirdev%2Fgatsby-plugin-tailwindcss/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273997210,"owners_count":25204499,"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","status":"online","status_checked_at":"2025-09-07T02:00:09.463Z","response_time":67,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["emotion","gatsby","gatsby-plugin","react","tailwind-css"],"created_at":"2024-07-31T17:00:39.485Z","updated_at":"2025-09-07T05:33:15.776Z","avatar_url":"https://github.com/muhajirdev.png","language":"JavaScript","funding_links":[],"categories":["Tools"],"sub_categories":[],"readme":"# Gatsby Plugin Tailwind CSS\n\n## What\n\nA Gatsby plugin to use Tailwind CSS with css-in-js. Like styled-components or emotion.js\n\n## TL;DR\n\nIf you want to quickly use Gatsby + Tailwind CSS + EmotionJS. There's already [gatsby-tailwind-emotion-starter](https://github.com/muhajirframe/gatsby-tailwind-emotion-starter)\n\n## Installation\n\nInside your Gatsby project\n\n```bash\nnpm install --save gatsby-plugin-tailwindcss tailwindcss\n```\n\nInit Tailwind configuration\n```\n./node_modules/.bin/tailwind init\n```\nIt will add `tailwind.js` to your root project\n\nAdd this plugin to your gatsby-config.js.\n\n```\nmodule.exports = {\n  plugins: ['gatsby-plugin-tailwindcss'],\n}\n```\n\nAdd `tw` global to your `.eslintrc`\n\n```\n{\n ...\n  \"globals\": {\n    \"tw\": true\n  },\n ...\n}\n```\n\nYou can now use Tailwind CSS with your favorite CSS-in-JS\n\nThis plugin use [babel-plugin-tailwind-components](https://github.com/bradlc/babel-plugin-tailwind-components) under the hood. \n\n## Usage\n\n### With Emotion\n\nInstall [gatsby-plugin-emotion](https://www.gatsbyjs.org/packages/gatsby-plugin-emotion/)\n\nIn your React Component\n\n```javascript\nimport React from 'react'\nimport styled from 'react-emotion'\n\n\nconst Container = styled.div`\n  ${tw`py-8`};\n`\nconst Text = styled.p`\n  ${tw`bg-black text-white`};\n`\n\nconst Home = () =\u003e (\n  \u003cContainer\u003e\n    \u003cText\u003eI am Text component made with Tailwind CSS + EmotionJS\u003c/Text\u003e\n  \u003c/Container\u003e\n)\n\nexport default Home\n```\n\n### With Styled Components\nInstall [gatsby-plugin-styled-components](https://www.gatsbyjs.org/packages/gatsby-plugin-styled-components/).\n\nIn your React Component\n\n```javascript\nimport React from 'react'\nimport styled from 'styled-components'\n\n\nconst Container = styled.div`\n  ${tw`py-8`};\n`\nconst Text = styled.p`\n  ${tw`bg-black text-white`};\n`\n\nconst Home = () =\u003e (\n  \u003cContainer\u003e\n    \u003cText\u003eI am Text component made with Tailwind CSS + Styled Components\u003c/Text\u003e\n  \u003c/Container\u003e\n)\n\nexport default Home\n```\n\n## Using Vscode\n\nTry this snippet plugin [vscode-tailwind-styled-snippets](https://github.com/muhajirframe/vscode-tailwind-styled-snippets)\n\n## For more information\n\n- [Github](https://github.com/muhajirframe/gatsby-plugin-tailwindcss/)\n- Got a question? [Submit an issue](https://github.com/muhajirframe/gatsby-plugin-tailwindcss/issues/new)\n\n## Contributing\n\n- [Submit an idea](https://github.com/muhajirframe/gatsby-plugin-tailwindcss/issues/new)\n- Make a pull request\n\n## Related\n\nI recently uses [`monad-ui`](https://github.com/muhajirdev/monad-ui). If you love tailwind, you might wanna try it too :)\n\n- [react-tailwind-emotion-starter](https://github.com/muhajirframe/react-tailwind-emotion-starter) A React + Tailwind + EmotionJs starter based on [create-react-app](https://github.com/facebook/create-react-app)\n- [vscode-tailwind-styled-snippets](https://github.com/muhajirframe/vscode-tailwind-styled-snippets) A Snippet Plugin For VSCode. Made with Tailwind + CSS-in-JS in mind.\n- [babel-plugin-tailwind-components](https://github.com/bradlc/babel-plugin-tailwind-components)\n- [gatsby-tailwind-emotion-starter](https://github.com/muhajirframe/gatsby-tailwind-emotion-starter)\n\n**Enjoy!**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmuhajirdev%2Fgatsby-plugin-tailwindcss","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmuhajirdev%2Fgatsby-plugin-tailwindcss","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmuhajirdev%2Fgatsby-plugin-tailwindcss/lists"}