Skip to content

Commit ea8dccd

Browse files
committed
update
1 parent 200cd8c commit ea8dccd

23 files changed

Lines changed: 138 additions & 1650 deletions

File tree

content/docs/contributing/docs.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,9 +146,6 @@ on.
146146
Some available variables:
147147

148148
- `GA_ID` – ID of the Google Analytics counter.
149-
- `ANALYZE` - boolean property to run
150-
[webpack-analyzer](https://www.gatsbyjs.com/plugins/gatsby-plugin-webpack-bundle-analyser-v2/).
151-
- `SENTRY_DSN` - [Sentry](https://sentry.io/welcome/) URL for errors tracking.
152149

153150
## Doc style guidelines (JavaScript and Markdown)
154151

gatsby-config.mjs

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,12 @@ import path from 'path'
55
import tailwindcssPostcss from '@tailwindcss/postcss'
66
import postcssNested from 'postcss-nested'
77

8-
import 'dotenv/config'
98
import './src/config/prismjs/dvc.js'
109
import './src/config/prismjs/dvctable.js'
1110
import simpleLinkerTerms from './content/linked-terms.js'
1211
import redirectsMiddleware from './server/redirect.js'
1312
import customYoutubeTransformer from './src/config/custom-yt-embedder.js'
1413
import makeGitHubMarkdownCssUseThemeAttribute from './src/config/postcss-theme-attribute.js'
15-
import sentryConfig from './src/config/sentry.js'
1614

1715
const require = createRequire(import.meta.url)
1816
const rootDir = import.meta.dirname
@@ -45,7 +43,6 @@ const docsPath = path.resolve('content', 'docs')
4543
const docsInstanceName = 'docs'
4644
const glossaryInstanceName = 'glossary'
4745
const argsLinkerPath = ['command-reference', 'ref', 'cli-reference']
48-
const sentry = true
4946

5047
const postCssPlugins = [
5148
postcssNested,
@@ -138,7 +135,7 @@ const plugins = [
138135
quotes: false
139136
}
140137
},
141-
'gatsby-remark-external-links',
138+
require.resolve('./src/plugins/remark-external-links'),
142139
{
143140
resolve: 'gatsby-remark-autolink-headers',
144141
options: {
@@ -157,7 +154,6 @@ const plugins = [
157154
}
158155
},
159156
require.resolve('./src/plugins/resize-image-plugin'),
160-
require.resolve('./src/plugins/external-link-plugin'),
161157
require.resolve('./src/plugins/null-link-plugin'),
162158
]
163159
}
@@ -190,10 +186,6 @@ const plugins = [
190186
}
191187
}
192188
},
193-
sentry && {
194-
resolve: '@sentry/gatsby',
195-
options: sentryConfig
196-
},
197189
'gatsby-plugin-catch-links',
198190
'gatsby-transformer-remark-frontmatter',
199191
{
@@ -291,11 +283,6 @@ if (process.env.GATSBY_GTM_ID) {
291283
})
292284
}
293285

294-
if (process.env.ANALYZE) {
295-
plugins.push({
296-
resolve: 'gatsby-plugin-webpack-bundle-analyser-v2'
297-
})
298-
}
299286

300287
export default {
301288
plugins: plugins.filter(Boolean),

gatsby-node.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ export const onCreatePage = ({ page, actions }) => {
103103
// Ignore warnings about CSS inclusion order, because we use CSS modules.
104104
// https://spectrum.chat/gatsby-js/general/having-issue-related-to-chunk-commons-mini-css-extract-plugin~0ee9c456-a37e-472a-a1a0-cc36f8ae6033?m=MTU3MjYyNDQ5OTAyNQ==
105105
export const onCreateWebpackConfig = ({ stage, actions, getConfig }) => {
106-
if (stage === 'build-javascript') {
106+
if (stage === 'build-javascript' || stage === 'develop') {
107107
const config = getConfig()
108108

109109
const miniCssExtractPlugin = config.plugins.find(

package.json

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,10 @@
4141
"dependencies": {
4242
"@babel/plugin-transform-react-jsx": "7.28.6",
4343
"@docsearch/modal": "4.6.2",
44-
"@sentry/gatsby": "10.46.0",
45-
"@sentry/node": "10.46.0",
4644
"@svgr/webpack": "8.1.0",
4745
"@tailwindcss/postcss": "4.2.2",
4846
"clsx": "2.1.1",
4947
"compression": "1.8.1",
50-
"dotenv": "17.3.1",
5148
"express": "5.2.1",
5249
"gatsby": "5.16.1",
5350
"gatsby-plugin-catch-links": "5.16.0",
@@ -59,7 +56,6 @@
5956
"gatsby-plugin-svgr": "3.0.0-beta.0",
6057
"gatsby-remark-autolink-headers": "6.16.0",
6158
"gatsby-remark-embedder": "7.0.0",
62-
"gatsby-remark-external-links": "0.0.4",
6359
"gatsby-remark-images": "7.16.0",
6460
"gatsby-remark-prismjs": "7.16.0",
6561
"gatsby-remark-smartypants": "6.16.0",
@@ -87,10 +83,8 @@
8783
"serve-handler": "6.1.7",
8884
"tailwindcss": "4.2.2",
8985
"tailwindcss-animate": "1.0.7",
90-
"title-case": "4.3.2",
9186
"unified": "11.0.5",
92-
"unist-util-visit": "5.1.0",
93-
"upath": "2.0.1"
87+
"unist-util-visit": "5.1.0"
9488
},
9589
"devDependencies": {
9690
"@babel/core": "7.29.0",
@@ -111,7 +105,6 @@
111105
"eslint-plugin-prettier": "5.5.5",
112106
"eslint-plugin-react": "7.37.5",
113107
"eslint-plugin-react-hooks": "6.1.1",
114-
"gatsby-plugin-webpack-bundle-analyser-v2": "1.1.32",
115108
"gatsby-source-filesystem": "5.16.0",
116109
"globals": "17.4.0",
117110
"happy-dom": "20.8.9",
@@ -127,9 +120,6 @@
127120
"vite-plugin-svgr": "4.5.0",
128121
"vitest": "4.1.2"
129122
},
130-
"resolutions": {
131-
"css-tree": "3.2.1"
132-
},
133123
"cacheDirectories": [
134124
"node_modules"
135125
],

renovate.json

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,6 @@
4949
"matchPackageNames": ["gatsby", "gatsby-*"],
5050
"matchDatasources": ["npm"]
5151
},
52-
{
53-
"groupName": "sentry",
54-
"matchPackageNames": ["@sentry/*"],
55-
"matchDatasources": ["npm"]
56-
},
5752
{
5853
"description": "Add typescript-eslint to the linters preset group",
5954
"groupName": "linters",

server/index.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
import './instrument.js'
2-
import 'dotenv/config'
3-
4-
import * as Sentry from '@sentry/node'
51
import compression from 'compression'
62
import express from 'express'
73
import helmet from 'helmet'
@@ -114,7 +110,6 @@ const serveMiddleware = async (req, res) => {
114110
})
115111
}
116112
app.use(serveMiddleware)
117-
Sentry.setupExpressErrorHandler(app)
118113

119114
// Error handler
120115
app.use(function onError(err, req, res, _next) {
@@ -123,7 +118,6 @@ app.use(function onError(err, req, res, _next) {
123118
const status = err?.status || 500
124119

125120
res.status(status).json({
126-
traceId: res.sentry,
127121
message: status === 500 ? 'Internal server error' : err.message
128122
})
129123
})

server/instrument.js

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/components/Documentation/Markdown/Tooltip/DesktopView/index.tsx

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -104,17 +104,23 @@ const DesktopView: React.FC<IDesktopViewProps> = ({
104104
}
105105

106106
useEffect(() => {
107-
document.addEventListener('scroll', calcPosition, { passive: true })
108-
window.addEventListener('resize', calcPosition, { passive: true })
107+
if (!isVisible) return
108+
109+
let rafId = requestAnimationFrame(calcPosition)
110+
const scheduleCalc = (): void => {
111+
if (!rafId)
112+
rafId = requestAnimationFrame(() => {
113+
rafId = 0
114+
calcPosition()
115+
})
116+
}
117+
document.addEventListener('scroll', scheduleCalc, { passive: true })
118+
window.addEventListener('resize', scheduleCalc, { passive: true })
109119

110120
return (): void => {
111-
document.removeEventListener('scroll', calcPosition)
112-
window.removeEventListener('resize', calcPosition)
113-
}
114-
}, [])
115-
useEffect(() => {
116-
if (isVisible) {
117-
requestAnimationFrame(calcPosition)
121+
document.removeEventListener('scroll', scheduleCalc)
122+
window.removeEventListener('resize', scheduleCalc)
123+
cancelAnimationFrame(rafId)
118124
}
119125
}, [isVisible])
120126

src/components/Search/styles.module.css

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@
3131
}
3232
}
3333

34+
.desktopTriggerText {
35+
overflow: hidden;
36+
white-space: nowrap;
37+
text-overflow: ellipsis;
38+
}
39+
3440
.desktopTriggerIcon {
3541
position: absolute;
3642
left: 15px;

src/config/sentry.js

Lines changed: 0 additions & 56 deletions
This file was deleted.

0 commit comments

Comments
 (0)