Skip to content

Commit 27d2c47

Browse files
committed
chore: fix prettier issues
1 parent b93a166 commit 27d2c47

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+774
-648
lines changed

.github/DISCUSSION_TEMPLATE/bug-report.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
labels: ["bug"]
1+
labels: ['bug']
22
body:
33
- type: markdown
44
attributes:

.github/ISSUE_TEMPLATE/bug_report.md

-2
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@ about: This is to create a new issue that already has an assignee. Please open a
44
title: ''
55
labels: ''
66
assignees: ''
7-
87
---
9-

examples/hacker_news/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
@@ -10,4 +10,4 @@
1010
<div id="root"></div>
1111
<script type="module" src="/src/index.tsx"></script>
1212
</body>
13-
</html>
13+
</html>

examples/hacker_news/vite.config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

44
export default defineConfig({
5-
plugins: [react()]
6-
})
5+
plugins: [react()],
6+
})

examples/hello/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
@@ -15,4 +15,4 @@
1515
<div id="root"></div>
1616
<script type="module" src="/src/index.tsx"></script>
1717
</body>
18-
</html>
18+
</html>

examples/hello/src/prism.css

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
code[class*='language-'],
77
pre[class*='language-'] {
88
color: #393a34;
9-
font-family: 'Consolas', 'Bitstream Vera Sans Mono', 'Courier New', Courier,
10-
monospace;
9+
font-family:
10+
'Consolas', 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace;
1111
direction: ltr;
1212
text-align: left;
1313
white-space: pre;

examples/hello/vite.config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

44
export default defineConfig({
5-
plugins: [react()]
6-
})
5+
plugins: [react()],
6+
})

examples/mega-form/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
@@ -10,4 +10,4 @@
1010
<div id="root"></div>
1111
<script type="module" src="/src/index.tsx"></script>
1212
</body>
13-
</html>
13+
</html>

examples/mega-form/src/style.css

+3-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,9 @@ body {
1010
margin: 0;
1111
padding: 8px;
1212
box-sizing: border-box;
13-
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
14-
Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
13+
font-family:
14+
-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu,
15+
Cantarell, 'Helvetica Neue', sans-serif;
1516
}
1617

1718
a {

examples/mega-form/vite.config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

44
export default defineConfig({
5-
plugins: [react()]
6-
})
5+
plugins: [react()],
6+
})

examples/starter/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />

examples/starter/src/index.tsx

+12-12
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
import { StrictMode } from 'react';
2-
import { createRoot } from 'react-dom/client';
3-
import { atom, useAtom } from 'jotai';
1+
import { StrictMode } from 'react'
2+
import { createRoot } from 'react-dom/client'
3+
import { atom, useAtom } from 'jotai'
44

5-
import mascot from './assets/jotai-mascot.png';
5+
import mascot from './assets/jotai-mascot.png'
66

7-
import './index.css';
7+
import './index.css'
88

9-
const countAtom = atom(0);
9+
const countAtom = atom(0)
1010

1111
const Counter = () => {
12-
const [count, setCount] = useAtom(countAtom);
13-
const inc = () => setCount((c) => c + 1);
12+
const [count, setCount] = useAtom(countAtom)
13+
const inc = () => setCount((c) => c + 1)
1414

1515
return (
1616
<>
@@ -22,8 +22,8 @@ const Counter = () => {
2222
+1
2323
</button>
2424
</>
25-
);
26-
};
25+
)
26+
}
2727

2828
function App() {
2929
return (
@@ -43,11 +43,11 @@ function App() {
4343

4444
<Counter />
4545
</div>
46-
);
46+
)
4747
}
4848

4949
createRoot(document.getElementById('root')!).render(
5050
<StrictMode>
5151
<App />
5252
</StrictMode>,
53-
);
53+
)

examples/starter/tsconfig.json

-1
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,3 @@
1919
"include": ["vite.config.ts", "./src/**/*"],
2020
"exclude": ["node_modules"]
2121
}
22-

examples/starter/vite.config.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import react from '@vitejs/plugin-react';
2-
import { defineConfig } from 'vite';
1+
import react from '@vitejs/plugin-react'
2+
import { defineConfig } from 'vite'
33

44
// https://vitejs.dev/config/
55
export default defineConfig({
66
plugins: [react()],
7-
});
7+
})

examples/text_length/index.html

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
@@ -22,7 +22,9 @@
2222
<div><div>REACT SPRING</div></div>
2323
</div>
2424
<div class="item-top">
25-
<a href="https://github.com/react-spring/jotai" target="_blank">GitHub</a>
25+
<a href="https://github.com/react-spring/jotai" target="_blank"
26+
>GitHub</a
27+
>
2628
</div>
2729
<div class="item-logo"><img src="/cover.svg" alt="Logo" /></div>
2830
<div class="item-demo" id="root"></div>

examples/text_length/vite.config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

44
export default defineConfig({
5-
plugins: [react()]
6-
})
5+
plugins: [react()],
6+
})

examples/todos/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
@@ -10,4 +10,4 @@
1010
<div id="root"></div>
1111
<script type="module" src="/src/index.tsx"></script>
1212
</body>
13-
</html>
13+
</html>

examples/todos/vite.config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

44
export default defineConfig({
5-
plugins: [react()]
6-
})
5+
plugins: [react()],
6+
})

examples/todos_with_atomFamily/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
@@ -10,4 +10,4 @@
1010
<div id="root"></div>
1111
<script type="module" src="/src/index.tsx"></script>
1212
</body>
13-
</html>
13+
</html>

examples/todos_with_atomFamily/vite.config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

44
export default defineConfig({
5-
plugins: [react()]
6-
})
5+
plugins: [react()],
6+
})

vitest.config.mts

+3-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ export default defineConfig({
3030
globals: true,
3131
environment: 'jsdom',
3232
dir: 'tests',
33-
reporters: process.env.GITHUB_ACTIONS ? ['default', 'github-actions'] : ['default'],
33+
reporters: process.env.GITHUB_ACTIONS
34+
? ['default', 'github-actions']
35+
: ['default'],
3436
setupFiles: ['tests/setup.ts'],
3537
coverage: {
3638
reporter: ['text', 'json', 'html', 'text-summary'],

website/.babelrc

+7-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,13 @@
55
{
66
"reactRuntime": "automatic",
77
"targets": {
8-
"browsers": [">0.25%", "not dead", "not ie <=11", "not ie_mob <=11", "not op_mini all"]
8+
"browsers": [
9+
">0.25%",
10+
"not dead",
11+
"not ie <=11",
12+
"not ie_mob <=11",
13+
"not op_mini all"
14+
]
915
}
1016
}
1117
]

website/api/contact.js

+9-9
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
import * as postmark from 'postmark';
1+
import * as postmark from 'postmark'
22

3-
const client = new postmark.ServerClient(process.env.POSTMARK_API_TOKEN);
3+
const client = new postmark.ServerClient(process.env.POSTMARK_API_TOKEN)
44

55
export default async function handler(request, response) {
6-
const body = request.body;
6+
const body = request.body
77

88
if (!body.name || !body.email || !body.message) {
9-
return response.status(400).json({ data: 'Invalid' });
9+
return response.status(400).json({ data: 'Invalid' })
1010
}
1111

12-
const subject = `Message from ${body.name} (${body.email}) via jotai.org`;
12+
const subject = `Message from ${body.name} (${body.email}) via jotai.org`
1313

1414
const message = `
1515
Name: ${body.name}\r\n
1616
Email: ${body.email}\r\n
1717
Message: ${body.message}
18-
`;
18+
`
1919

2020
try {
2121
await client.sendEmail({
@@ -24,10 +24,10 @@ export default async function handler(request, response) {
2424
Subject: subject,
2525
ReplyTo: body.email,
2626
TextBody: message,
27-
});
27+
})
2828

29-
response.status(200).json({ status: 'Sent' });
29+
response.status(200).json({ status: 'Sent' })
3030
} catch (error) {
31-
response.status(500).json({ status: 'Not sent' });
31+
response.status(500).json({ status: 'Not sent' })
3232
}
3333
}

website/gatsby-browser.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
import './src/styles/index.css';
1+
import './src/styles/index.css'
22

3-
export { wrapRootElement, wrapPageElement } from './gatsby-shared.js';
3+
export { wrapRootElement, wrapPageElement } from './gatsby-shared.js'

website/gatsby-config.js

+17-15
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
/* eslint-disable @typescript-eslint/no-var-requires */
2-
require('dotenv').config();
2+
require('dotenv').config()
33

4-
const kebabCase = require('just-kebab-case');
4+
const kebabCase = require('just-kebab-case')
55
const getAnchor = (value) => {
6-
return typeof value === 'string' ? kebabCase(value.toLowerCase().replaceAll("'", '')) : '';
7-
};
6+
return typeof value === 'string'
7+
? kebabCase(value.toLowerCase().replaceAll("'", ''))
8+
: ''
9+
}
810

911
const DOCS_QUERY = `
1012
query {
@@ -24,13 +26,13 @@ const DOCS_QUERY = `
2426
}
2527
}
2628
}
27-
`;
29+
`
2830

2931
const queries = [
3032
{
3133
query: DOCS_QUERY,
3234
transformer: ({ data }) => {
33-
const results = [];
35+
const results = []
3436

3537
data.allMdx.nodes.forEach((item) => {
3638
const transformedNode = {
@@ -43,7 +45,7 @@ const queries = [
4345
headings: item.headings.map((heading) => heading.value).join(' '),
4446
body: item.rawBody.replace(/(<([^>]+)>)/gi, ''),
4547
level: 1,
46-
};
48+
}
4749

4850
if (item.slug !== 'introduction') {
4951
item.headings
@@ -59,16 +61,16 @@ const queries = [
5961
headings: [],
6062
body: '',
6163
level: 2,
62-
};
64+
}
6365

64-
results.push(transformedNode);
65-
});
66+
results.push(transformedNode)
67+
})
6668
}
6769

68-
results.push(transformedNode);
69-
});
70+
results.push(transformedNode)
71+
})
7072

71-
return results;
73+
return results
7274
},
7375
indexName: 'Docs',
7476
settings: {
@@ -85,7 +87,7 @@ const queries = [
8587
},
8688
mergeSettings: false,
8789
},
88-
];
90+
]
8991

9092
module.exports = {
9193
siteMetadata: {
@@ -145,4 +147,4 @@ module.exports = {
145147
jsxRuntime: 'automatic',
146148
polyfill: false,
147149
trailingSlash: 'never',
148-
};
150+
}

0 commit comments

Comments
 (0)