Skip to content

Commit

Permalink
feat: Modified to allow specification of prettier configuration files
Browse files Browse the repository at this point in the history
  • Loading branch information
activeguild committed Nov 24, 2023
1 parent 6dab402 commit 5ec5f40
Show file tree
Hide file tree
Showing 10 changed files with 5,743 additions and 2,446 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ npm i -D vite-plugin-sass-dts
| typeName.replacement | string \| (fileName: string) => string | Type name can be changed to any value. (default is the classname key as a string. e.g. `theClassName: 'theClassName';`) |
| outputDir | string | An absolute path to the output directory. If undefined, declaration files will be generated in the source directories. `) |
| sourceDir | string | An absolute path to your source code directory. The plugin will replace this path with `outputDir` option when writing declaration files. `) |
| prettierFilePath | string | Specify the path to the prettier configuration file. |
| prettierFilePath | string | Specify the path to the prettier configuration file. |

## Add it to vite.config.ts

Expand Down
2 changes: 1 addition & 1 deletion example/nuxt-sass/.prettierrc.cjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
trailingComma: 'es5',
trailingComma: "es5",
tabWidth: 2,
semi: false,
singleQuote: false,
Expand Down
2 changes: 1 addition & 1 deletion example/nuxt-sass/app.module.scss.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
declare const classNames: {
readonly foo: 'foo'
readonly foo: "foo"
}
export = classNames
4 changes: 2 additions & 2 deletions example/nuxt-sass/app.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
</template>

<script setup>
import styles from './app.module.scss'
console.log('styles :>> ', styles)
import styles from "./app.module.scss"
console.log("styles :>> ", styles)
</script>

<style module lang="scss">
Expand Down
4 changes: 2 additions & 2 deletions example/nuxt-sass/nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { defineNuxtConfig } from 'nuxt/config'
import sassDts from 'vite-plugin-sass-dts'
import { defineNuxtConfig } from "nuxt/config"
import sassDts from "vite-plugin-sass-dts"

// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
Expand Down
Loading

1 comment on commit 5ec5f40

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bundled size for the package is listed below:

dist: 42.97 KB

Please sign in to comment.