Skip to content

Commit

Permalink
chore(pkg): bump deps
Browse files Browse the repository at this point in the history
  • Loading branch information
harlan-zw committed Apr 12, 2023
1 parent d809a37 commit 93c5ab3
Show file tree
Hide file tree
Showing 8 changed files with 4,683 additions and 4,478 deletions.
20 changes: 10 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,17 @@
"test": "vitest"
},
"devDependencies": {
"@antfu/eslint-config": "^0.31.0",
"@nuxt/test-utils": "3.0.0",
"@nuxt/types": "^2.15.8",
"@typescript-eslint/eslint-plugin": "^5.44.0",
"@typescript-eslint/visitor-keys": "^5.44.0",
"bumpp": "^8.2.1",
"@antfu/eslint-config": "^0.38.4",
"@nuxt/test-utils": "3.4.0",
"@nuxt/types": "^2.16.3",
"@typescript-eslint/eslint-plugin": "^5.58.0",
"@typescript-eslint/visitor-keys": "^5.58.0",
"bumpp": "^9.1.0",
"cheerio": "1.0.0-rc.12",
"eslint": "^8.28.0",
"unbuild": "^1.0.1",
"vite": "^3.2.4",
"vitest": "^0.25.3",
"eslint": "^8.38.0",
"unbuild": "^1.2.0",
"vite": "^4.2.1",
"vitest": "^0.30.1",
"windicss": "^3.5.6"
},
"version": "2.6.0"
Expand Down
32 changes: 16 additions & 16 deletions packages/nuxt-windicss/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,27 +38,27 @@
"build": "nuxt-module-build"
},
"dependencies": {
"@nuxt/kit": "3.0.0",
"@windicss/config": "^1.8.8",
"@windicss/plugin-utils": "^1.8.8",
"consola": "^2.15.3",
"defu": "^6.1.1",
"fs-extra": "^10.1.0",
"h3": "^1.0.1",
"listhen": "^1.0.0",
"pathe": "^1.0.0",
"@nuxt/kit": "3.4.0",
"@windicss/config": "^1.8.10",
"@windicss/plugin-utils": "^1.8.10",
"consola": "^3.0.1",
"defu": "^6.1.2",
"fs-extra": "^11.1.1",
"h3": "^1.6.4",
"listhen": "^1.0.4",
"pathe": "^1.1.0",
"read-cache": "^1.0.0",
"sirv": "^2.0.2",
"vite-plugin-windicss": "^1.8.8",
"vite-plugin-windicss": "^1.8.10",
"windicss": "^3.5.6",
"windicss-analysis": "^0.3.5",
"windicss-webpack-plugin": "^1.7.7"
"windicss-webpack-plugin": "^1.7.8"
},
"devDependencies": {
"@nuxt/content": "^2.2.2",
"@nuxt/module-builder": "^0.2.1",
"@nuxt/schema": "3.0.0",
"@nuxt/types": "^2.15.8",
"@types/fs-extra": "^9.0.13"
"@nuxt/content": "^2.5.2",
"@nuxt/module-builder": "^0.3.0",
"@nuxt/schema": "3.4.0",
"@nuxt/types": "^2.16.3",
"@types/fs-extra": "^11.0.1"
}
}
13 changes: 6 additions & 7 deletions packages/nuxt-windicss/src/module.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import { readFileSync, writeFileSync } from 'fs'
import { readFileSync, writeFileSync } from 'node:fs'
import { ensureDirSync } from 'fs-extra'
import { join, relative, resolve } from 'pathe'
import { createUtils } from '@windicss/plugin-utils'
import type { ResolvedOptions, UserOptions, WindiPluginUtils } from '@windicss/plugin-utils'
import type { Config } from 'windicss/types/interfaces'
import {
clearRequireCache,
createResolver,
defineNuxtModule,
extendViteConfig,
Expand Down Expand Up @@ -153,12 +152,12 @@ export default defineNuxtModule<ModuleOptions>({
let configType = 'inline'
// this hook is ran twice for some reason
if (configFilePath) {
clearRequireCache(configFilePath)
// clearRequireCache(configFilePath)
configType = `./${relative(nuxtOptions.rootDir, configFilePath)}`
// Restart Nuxt if windi file updates (for modules using windicss:config hook)
// @ts-expect-error nuxt2
// @ts-ignore nuxt2
if (nuxt.options.dev && nuxt.options.watch)
// @ts-expect-error nuxt2
// @ts-ignore nuxt2
nuxt.options.watch.push(configFilePath)
}

Expand All @@ -175,9 +174,9 @@ export default defineNuxtModule<ModuleOptions>({
if (!filepath || !config)
return

// @ts-expect-error nuxt2
// @ts-ignore nuxt2
if (nuxt.options.dev && nuxt.options.watch)
// @ts-expect-error nuxt2
// @ts-ignore nuxt2
nuxt.options.watch.push(filepath)
// fix recursion
// delete config.plugins
Expand Down
2 changes: 1 addition & 1 deletion playground/nuxt2-vite/__snapshots__/module.test.ts.snap
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Vitest Snapshot v1
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html

exports[`nuxt2-webpack > index html transformed correctly > script-0 1`] = `"*,:after,:before{box-sizing:border-box;border:0 solid #e7e5e4}*{--tw-ring-inset:var(--tw-empty, );/*!*//*!*/--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(14,165,233,0.5);--tw-ring-offset-shadow:0 0 transparent;--tw-ring-shadow:0 0 transparent;--tw-shadow:0 0 transparent}:root{-moz-tab-size:4;-o-tab-size:4;tab-size:4}:-moz-focusring{outline:1px dotted ButtonText}:-moz-ui-invalid{box-shadow:none}::moz-focus-inner{border-style:none;padding:0}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}a{color:inherit;text-decoration:inherit}body{line-height:inherit}body,button{margin:0;font-family:inherit}button{font-size:100%;line-height:1.15;text-transform:none;background-color:transparent;background-image:none;padding:0;line-height:inherit;color:inherit}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[role=button],button{cursor:pointer}html{-webkit-text-size-adjust:100%;font-family:Inter var,ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,BlinkMacSystemFont,\\"Segoe UI\\",\\"Helvetica Neue\\",Arial,\\"Noto Sans\\",\\"Apple Color Emoji\\",\\"Segoe UI Emoji\\",\\"Segoe UI Symbol\\",\\"Noto Color Emoji\\";line-height:1.5}h1,h2,h3{font-size:inherit;font-weight:inherit}img{border-style:solid;display:block;vertical-align:middle;max-width:100%;height:auto}h1,h2,h3,p,ul{margin:0}ul{list-style:none;padding:0}.prose{color:#374151;max-width:65ch;font-size:1rem;line-height:1.75}.prose [class~=lead]{color:#4b5563;font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.prose a{color:#111827;text-decoration:underline;font-weight:500}.prose strong{color:#111827;font-weight:600}.prose ol[type=A]{--list-counter-style:upper-alpha}.prose ol[type=a]{--list-counter-style:lower-alpha}.prose ol[type=\\"A s\\"]{--list-counter-style:upper-alpha}.prose ol[type=\\"a s\\"]{--list-counter-style:lower-alpha}.prose ol[type=I]{--list-counter-style:upper-roman}.prose ol[type=i]{--list-counter-style:lower-roman}.prose ol[type=\\"I s\\"]{--list-counter-style:upper-roman}.prose ol[type=\\"i s\\"]{--list-counter-style:lower-roman}.prose ol[type=\\"1\\"]{--list-counter-style:decimal}.prose ol>li{position:relative;padding-left:1.75em}.prose ol>li:before{content:counter(list-item,decimal) \\".\\";content:counter(list-item,var(--list-counter-style,decimal)) \\".\\";position:absolute;font-weight:400;color:#6b7280;left:0}.prose ul>li{position:relative;padding-left:1.75em}.prose ul>li:before{content:\\"\\";position:absolute;background-color:#d1d5db;border-radius:50%;width:.375em;height:.375em;top:.6875em;left:.25em}.prose hr{border-color:#e5e7eb;margin-top:3em;margin-bottom:3em}.prose blockquote{font-weight:500;font-style:italic;color:#111827;border-left-width:.25rem;border-color:#e5e7eb;quotes:\\"\\\\201C\\"\\"\\\\201D\\"\\"\\\\2018\\"\\"\\\\2019\\";margin-top:1.6em;margin-bottom:1.6em;padding-left:1em}.prose blockquote p:first-of-type:before{content:open-quote}.prose blockquote p:last-of-type:after{content:close-quote}.prose h1{color:#111827;font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.prose h2{color:#111827;font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.prose h3{font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.prose h3,.prose h4{color:#111827;font-weight:600}.prose h4{margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.prose figure figcaption{color:#6b7280;font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose code{color:#111827;font-weight:600;font-size:.875em}.prose code:after,.prose code:before{content:\\"\`\\"}.prose a code{color:#111827}.prose pre{color:#e5e7eb;background-color:#1f2937;overflow-x:auto;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding:.8571429em 1.1428571em}.prose pre code{background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:400;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.prose pre code:after,.prose pre code:before{content:none}.prose table{width:100%;table-layout:auto;text-align:left;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.prose thead{color:#111827;font-weight:600;border-bottom-width:1px;border-bottom-color:#d1d5db}.prose thead th{vertical-align:bottom;padding-right:.5714286em;padding-bottom:.5714286em;padding-left:.5714286em}.prose tbody tr{border-bottom-width:1px;border-bottom-color:#e5e7eb}.prose tbody tr:last-child{border-bottom-width:0}.prose tbody td{vertical-align:top;padding:.5714286em}.prose p{margin-top:1.25em;margin-bottom:1.25em}.prose figure,.prose img,.prose video{margin-top:2em;margin-bottom:2em}.prose figure>*{margin-top:0;margin-bottom:0}.prose h2 code{font-size:.875em}.prose h3 code{font-size:.9em}.prose ol,.prose ul{margin-top:1.25em;margin-bottom:1.25em;list-style-type:none}.prose li{margin-top:.5em;margin-bottom:.5em}.prose>ul>li p{margin-top:.75em;margin-bottom:.75em}.prose>ul>li>:first-child{margin-top:1.25em}.prose>ul>li>:last-child{margin-bottom:1.25em}.prose>ol>li>:first-child{margin-top:1.25em}.prose>ol>li>:last-child{margin-bottom:1.25em}.prose ol ol,.prose ol ul,.prose ul ol,.prose ul ul{margin-top:.75em;margin-bottom:.75em}.prose h2+*,.prose h3+*,.prose h4+*,.prose hr+*{margin-top:0}.prose thead th:first-child{padding-left:0}.prose thead th:last-child{padding-right:0}.prose tbody td:first-child{padding-left:0}.prose tbody td:last-child{padding-right:0}.prose>:first-child{margin-top:0}.prose>:last-child{margin-bottom:0}.prose-xl{font-size:1.25rem;line-height:1.8}.prose-xl p{margin-top:1.2em;margin-bottom:1.2em}.prose-xl [class~=lead]{font-size:1.2em;line-height:1.5;margin-top:1em;margin-bottom:1em}.prose-xl blockquote{margin-top:1.6em;margin-bottom:1.6em;padding-left:1.0666667em}.prose-xl h1{font-size:2.8em;margin-top:0;margin-bottom:.8571429em;line-height:1}.prose-xl h2{font-size:1.8em;margin-top:1.5555556em;margin-bottom:.8888889em;line-height:1.1111111}.prose-xl h3{font-size:1.5em;margin-top:1.6em;margin-bottom:.6666667em;line-height:1.3333333}.prose-xl h4{margin-top:1.8em;margin-bottom:.6em;line-height:1.6}.prose-xl figure,.prose-xl img,.prose-xl video{margin-top:2em;margin-bottom:2em}.prose-xl figure>*{margin-top:0;margin-bottom:0}.prose-xl figure figcaption{font-size:.9em;line-height:1.5555556;margin-top:1em}.prose-xl code{font-size:.9em}.prose-xl h2 code{font-size:.8611111em}.prose-xl h3 code,.prose-xl pre{font-size:.9em}.prose-xl pre{line-height:1.7777778;margin-top:2em;margin-bottom:2em;border-radius:.5rem;padding:1.1111111em 1.3333333em}.prose-xl ol,.prose-xl ul{margin-top:1.2em;margin-bottom:1.2em}.prose-xl li{margin-top:.6em;margin-bottom:.6em}.prose-xl ol>li{padding-left:1.8em}.prose-xl ol>li:before{left:0}.prose-xl ul>li{padding-left:1.8em}.prose-xl ul>li:before{width:.35em;height:.35em;top:.725em;left:.25em}.prose-xl>ul>li p{margin-top:.8em;margin-bottom:.8em}.prose-xl>ul>li>:first-child{margin-top:1.2em}.prose-xl>ul>li>:last-child{margin-bottom:1.2em}.prose-xl>ol>li>:first-child{margin-top:1.2em}.prose-xl>ol>li>:last-child{margin-bottom:1.2em}.prose-xl ol ol,.prose-xl ol ul,.prose-xl ul ol,.prose-xl ul ul{margin-top:.8em;margin-bottom:.8em}.prose-xl hr{margin-top:2.8em;margin-bottom:2.8em}.prose-xl h2+*,.prose-xl h3+*,.prose-xl h4+*,.prose-xl hr+*{margin-top:0}.prose-xl table{font-size:.9em;line-height:1.5555556}.prose-xl thead th{padding-right:.6666667em;padding-bottom:.8888889em;padding-left:.6666667em}.prose-xl thead th:first-child{padding-left:0}.prose-xl thead th:last-child{padding-right:0}.prose-xl tbody td{padding:.8888889em .6666667em}.prose-xl tbody td:first-child{padding-left:0}.prose-xl tbody td:last-child{padding-right:0}.prose-xl>:first-child{margin-top:0}.prose-xl>:last-child{margin-bottom:0}.bg-gray-50{--tw-bg-opacity:1;background-color:rgba(250,250,249,var(--tw-bg-opacity))}.bg-yellow-400{--tw-bg-opacity:1;background-color:rgba(251,191,36,var(--tw-bg-opacity))}.hover\\\\:bg-yellow-900:hover{--tw-bg-opacity:1;background-color:rgba(120,53,15,var(--tw-bg-opacity))}.bg-purple-400{--tw-bg-opacity:1;background-color:rgba(192,132,252,var(--tw-bg-opacity))}.hover\\\\:bg-purple-900:hover{--tw-bg-opacity:1;background-color:rgba(88,28,135,var(--tw-bg-opacity))}.bg-pink-400{--tw-bg-opacity:1;background-color:rgba(244,114,182,var(--tw-bg-opacity))}.hover\\\\:bg-pink-900:hover{--tw-bg-opacity:1;background-color:rgba(131,24,67,var(--tw-bg-opacity))}.bg-orange-400{--tw-bg-opacity:1;background-color:rgba(251,146,60,var(--tw-bg-opacity))}.hover\\\\:bg-orange-900:hover{--tw-bg-opacity:1;background-color:rgba(124,45,18,var(--tw-bg-opacity))}.bg-blue-400{--tw-bg-opacity:1;background-color:rgba(56,189,248,var(--tw-bg-opacity))}.hover\\\\:bg-blue-900:hover{--tw-bg-opacity:1;background-color:rgba(12,74,110,var(--tw-bg-opacity))}.bg-red-400{--tw-bg-opacity:1;background-color:rgba(248,113,113,var(--tw-bg-opacity))}.hover\\\\:bg-red-900:hover{--tw-bg-opacity:1;background-color:rgba(127,29,29,var(--tw-bg-opacity))}.bg-purple-100{--tw-bg-opacity:1;background-color:rgba(243,232,255,var(--tw-bg-opacity))}.hover\\\\:bg-purple-800:hover{--tw-bg-opacity:1;background-color:rgba(107,33,168,var(--tw-bg-opacity))}.rounded-full{border-radius:9999px}.rounded{border-radius:.25rem}.block{display:block}.inline{display:inline}.flex{display:flex}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-center{justify-content:center}.font-bold{font-weight:700}.h-40{height:10rem}.h-full{height:100%}.h-120{height:30rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-2xl{font-size:1.5rem;line-height:2rem}.my-10{margin-top:2.5rem;margin-bottom:2.5rem}.mx-auto{margin-left:auto;margin-right:auto}.mt-12{margin-top:3rem}.mt-2{margin-top:.5rem}.mb-5{margin-bottom:1.25rem}.opacity-80{opacity:.8}.p-4{padding:1rem}.p-5{padding:1.25rem}.py-5{padding-top:1.25rem;padding-bottom:1.25rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.pl-50px{padding-left:50px}.pb-5{padding-bottom:1.25rem}.absolute{position:absolute}.relative{position:relative}.left-1\\\\/2{left:50%}.top-45{top:11.25rem}.text-center{text-align:center}.text-white{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.hover\\\\:text-purple-100:hover{--tw-text-opacity:1;color:rgba(243,232,255,var(--tw-text-opacity))}.hover\\\\:text-orange-100:hover{--tw-text-opacity:1;color:rgba(255,237,213,var(--tw-text-opacity))}.hover\\\\:text-red-100:hover{--tw-text-opacity:1;color:rgba(254,226,226,var(--tw-text-opacity))}.text-green-50{--tw-text-opacity:1;color:rgba(236,253,245,var(--tw-text-opacity))}.text-red-900{--tw-text-opacity:1;color:rgba(127,29,29,var(--tw-text-opacity))}.underline{-webkit-text-decoration-line:underline;text-decoration-line:underline}.w-full{width:100%}.w-40{width:10rem}.w-1\\\\/4{width:25%}.w-20{width:5rem}.w-120{width:30rem}.z-20{z-index:20}.gap-4{grid-gap:1rem;gap:1rem}.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate:0;--tw-rotate-x:0;--tw-rotate-y:0;--tw-rotate-z:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotate(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z))}.hover\\\\:rotate-45:hover{--tw-rotate:45deg}.transition{transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}@keyframes pulse{0%,to{opacity:1}50%{opacity:.5}}@-webkit-keyframes pulse{0%,to{opacity:1}50%{opacity:.5}}.animate-pulse{-webkit-animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite;animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}.filter{--tw-blur:var(--tw-empty, );/*!*//*!*/--tw-brightness:var(--tw-empty, );/*!*//*!*/--tw-contrast:var(--tw-empty, );/*!*//*!*/--tw-grayscale:var(--tw-empty, );/*!*//*!*/--tw-hue-rotate:var(--tw-empty, );/*!*//*!*/--tw-invert:var(--tw-empty, );/*!*//*!*/--tw-saturate:var(--tw-empty, );/*!*//*!*/--tw-sepia:var(--tw-empty, );/*!*//*!*/--tw-drop-shadow:var(--tw-empty, );/*!*//*!*/filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.blur-sm{--tw-blur:blur(4px)}.grayscale{--tw-grayscale:grayscale(100%)}"`;

Expand Down
2 changes: 1 addition & 1 deletion playground/nuxt2-webpack/module.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { describe, test, expect } from 'vitest'
import cheerio from 'cheerio'
import execa from 'execa'

const execa = require('execa');
const fs = require('fs')
const path = require('pathe')

Expand Down
6 changes: 3 additions & 3 deletions playground/nuxt3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
"start": "node .output/server/index.mjs"
},
"devDependencies": {
"@nuxt/content": "^2.2.2",
"@nuxt/content": "^2.5.2",
"less": "^4.1.2",
"nuxt": "^3.0.0",
"nuxt": "^3.4.0",
"nuxt-windicss": "link:../../packages/nuxt-windicss",
"sass": "^1.56.1",
"sass": "^1.62.0",
"stylus": "^0.59.0"
}
}

0 comments on commit 93c5ab3

Please sign in to comment.