Skip to content

Commit

Permalink
fix: compiled for sanity 3.0.0-rc.0
Browse files Browse the repository at this point in the history
Upgraded with
"npx @sanity/plugin-kit inject --preset semver-workflow --preset renovatebot"
  • Loading branch information
snorrees committed Nov 2, 2022
1 parent a7b76d3 commit ccf2b61
Show file tree
Hide file tree
Showing 14 changed files with 3,022 additions and 905 deletions.
13 changes: 13 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
; editorconfig.org
root = true
charset= utf8

[*]
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 2

[*.md]
trim_trailing_whitespace = false
2 changes: 1 addition & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
commitlint.config.js
lib
lint-staged.config.js
*.js
package.config.ts
*.js
14 changes: 14 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"root": true,
"env": {
"node": true,
"browser": true
},
"extends": [
"sanity",
"sanity/typescript",
"sanity/react",
"plugin:react-hooks/recommended",
"plugin:prettier/recommended"
]
}
53 changes: 44 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,22 +1,57 @@
# Logs
/logs
logs
*.log
npm-debug.log*

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
/coverage
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directories
/node_modules
node_modules
jspm_packages

# Compiled code
/lib
# Optional npm cache directory
.npm

# Optional REPL history
.node_repl_history

# macOS finder cache file
.DS_Store

# VS Code settings
.vscode

# IntelliJ
.idea/
.idea
*.iml

# yalc
# Cache
.cache

# Compiled plugin
lib

# Yalc
.yalc
yalc.lock

.parcel-cache
18 changes: 8 additions & 10 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
/coverage
/scripts
/test
/.babelrc
/.depcheckignore.json
/.eslintignore
/.eslintrc
/jest.config.js
/tsconfig.json
/tsconfig.lib.json
.idea/
/coverage
.editorconfig
.eslintrc
.gitignore
.github
.prettierrc
.travis.yml
.nyc_output
9 changes: 0 additions & 9 deletions .parcelrc

This file was deleted.

6 changes: 0 additions & 6 deletions .prettierrc

This file was deleted.

6 changes: 6 additions & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
semi: false,
printWidth: 100,
bracketSpacing: false,
singleQuote: true,
}
13 changes: 2 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,18 +179,9 @@ with default configuration for build & watch scripts.
See [Testing a plugin in Sanity Studio](https://github.com/sanity-io/plugin-kit#testing-a-plugin-in-sanity-studio)
on how to run this plugin with hotreload in the studio.

### Dev note on parcel + vite in dev mode:
Vite will emit a warning when using yalc add + link in a Studio running with
vite dev server.
It happens because parcel appends ?currentTimestamp to the import statement for
cache busting, which is [not supported by vite](https://github.com/rollup/plugins/tree/master/packages/dynamic-import-vars#limitations).
### Release new version

However, the code _works_, and when building for production this is not an issue, as parcel
will not suffix the timestamp in the prod bundle.

## Release new version

Run ["CI & Release" workflow](https://github.com/sanity-io/code-input/actions).
Run ["CI & Release" workflow](https://github.com/sanity-io/code-input/actions/workflows/main.yml).
Make sure to select the main branch and check "Release new version".

Semantic release will only release on configured branches, so it is safe to run release on any branch.
Loading

0 comments on commit ccf2b61

Please sign in to comment.