{"id":592,"date":"2021-05-07T17:14:41","date_gmt":"2021-05-07T08:14:41","guid":{"rendered":"http:\/\/www.agile-software.site\/?p=592"},"modified":"2022-11-27T17:12:48","modified_gmt":"2022-11-27T08:12:48","slug":"tailwindcss","status":"publish","type":"post","link":"https:\/\/agile-software.net\/?p=592","title":{"rendered":"tailwindcss"},"content":{"rendered":"\n<p>Tailwind CSS\u3067\u306f\u30d5\u30a9\u30f3\u30c8\u306e\u5927\u304d\u3055\u3084\u8272\u3001\u30de\u30fc\u30b8\u30f3\u3001\u30d1\u30c7\u30a3\u30f3\u30b0\u306a\u3069\u3055\u307e\u3056\u307e\u306a\u30af\u30e9\u30b9\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u3066\u3001\u3053\u308c\u3089\u3092\u7d44\u307f\u5408\u308f\u305b\u3066\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-jin-gb-block-box-with-headline kaisetsu-box5\"><div class=\"kaisetsu-box5-title\">Utility-First\u00a0<\/div>\n<p>\u8907\u96d1\u306a\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u3064\u304f\u308b\u305f\u3081\u306e\u5358\u7d14\u3067\u6271\u3044\u3084\u3059\u3044\u6a5f\u80fd\u3092\u96c6\u3081\u305f<\/p>\n<\/div>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-plain\"><code>&lt;!-- \u516c\u5f0f\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u304b\u3089\u5f15\u7528 --&gt;\n&lt;!-- class \u5c5e\u6027\u306b\u4ed8\u4e0e\u3055\u3066\u3044\u308b\u306e\u306f\u5168\u3066 utility class --&gt;\n&lt;div class=&quot;p-6 max-w-sm mx-auto bg-white rounded-xl shadow-md flex items-center space-x-4&quot;&gt;\n  &lt;div class=&quot;flex-shrink-0&quot;&gt;\n    &lt;img class=&quot;h-12 w-12&quot; src=&quot;\/img\/logo.svg&quot; alt=&quot;ChitChat Logo&quot;&gt;\n  &lt;\/div&gt;\n  &lt;div&gt;\n    &lt;div class=&quot;text-xl font-medium text-black&quot;&gt;ChitChat&lt;\/div&gt;\n    &lt;p class=&quot;text-gray-500&quot;&gt;You have a new message!&lt;\/p&gt;\n  &lt;\/div&gt;\n&lt;\/div&gt;<\/code><\/pre><\/div>\n\n\n\n<div class=\"wp-block-jin-gb-block-box-with-headline kaisetsu-box1\"><div class=\"kaisetsu-box1-title\">\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8<\/div>\n<p><strong>\u30d5\u30a1\u30a4\u30eb\u3084\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u69cb\u6210\u8981\u7d20<\/strong><\/p>\n<\/div>\n\n\n\n<h2 class=\"wp-block-heading\">\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5<\/h2>\n\n\n\n<p>Tailwind\u306e\u5c0e\u5165\u306f\u3001\u57fa\u672c\u7684\u306bnodejs\u304c\u5fc5\u8981\u3067\u3059\uff08nodejs\u3067\u6210\u679c\u7269CSS\u3092\u30d3\u30eb\u30c9\u3059\u308b\uff09\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">npm\u7d4c\u7531\u3067\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b<\/h3>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-plain\"><code>npm install -D tailwindcss@latest postcss@latest autoprefixer@latest<\/code><\/pre><\/div>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-plain\"><code>npx tailwindcss init -p<\/code><\/pre><\/div>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-plain\" data-file=\"tailwind.config.js\"><code>module.exports = {\n  purge: [&quot;.\/pages\/**\/*.{js,ts,jsx,tsx}&quot;, &quot;.\/components\/**\/*.{js,ts,jsx,tsx}&quot;],\n  darkMode: false, \/\/ or &#39;media&#39; or &#39;class&#39;\n  theme: {\n    extend: {},\n  },\n  variants: {\n    extend: {},\n  },\n  plugins: [],\n};<\/code><\/pre><\/div>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-plain\" data-file=\"styles\/global.css\"><code>@tailwind base;\n@tailwind components;\n@tailwind utilities;<\/code><\/pre><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">CDN\u7d4c\u7531\u3067Tailwind\u3092\u8aad\u307f\u8fbc\u3080<\/h3>\n\n\n\n<p>\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u3092&lt;head&gt;\u5185\u306b\u8a18\u8ff0\u3059\u308c\u3070\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-plain\"><code>&lt;link href=&quot;https:\/\/unpkg.com\/tailwindcss@^2\/dist\/tailwind.min.css&quot; rel=&quot;stylesheet&quot;&gt;<\/code><\/pre><\/div>\n\n\n\n<script async=\"\" src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-4276705529344958\" crossorigin=\"anonymous\"><\/script>\n<!-- Agile\u80b2\u6210\u30d6\u30ed\u30b0 -->\n<ins class=\"adsbygoogle\" style=\"display:block\" data-ad-client=\"ca-pub-4276705529344958\" data-ad-slot=\"9009931297\" data-ad-format=\"auto\" data-full-width-responsive=\"true\"><\/ins>\n<script>\n     (adsbygoogle = window.adsbygoogle || []).push({});\n<\/script>\n","protected":false},"excerpt":{"rendered":"<p>Tailwind CSS\u3067\u306f\u30d5\u30a9\u30f3\u30c8\u306e\u5927\u304d\u3055\u3084\u8272\u3001\u30de\u30fc\u30b8\u30f3\u3001\u30d1\u30c7\u30a3\u30f3\u30b0\u306a\u3069\u3055\u307e\u3056\u307e\u306a\u30af\u30e9\u30b9\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u3066\u3001\u3053\u308c\u3089\u3092\u7d44\u307f\u5408\u308f\u305b\u3066\u4f7f\u7528\u3057\u307e\u3059\u3002 \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5 Tailwind\u306e\u5c0e\u5165\u306f\u3001\u57fa\u672c\u7684\u306bnodejs\u304c\u5fc5\u8981\u3067\u3059\uff08n<\/p>\n","protected":false},"author":1,"featured_media":794,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jin_ogp_image_url":"","_jin_last_featured_id":0,"footnotes":""},"categories":[7],"tags":[],"class_list":["post-592","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-css"],"_links":{"self":[{"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/posts\/592","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/agile-software.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=592"}],"version-history":[{"count":5,"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/posts\/592\/revisions"}],"predecessor-version":[{"id":2274,"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/posts\/592\/revisions\/2274"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/agile-software.net\/index.php?rest_route=\/wp\/v2\/media\/794"}],"wp:attachment":[{"href":"https:\/\/agile-software.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=592"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/agile-software.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=592"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/agile-software.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=592"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}