fix(slider): resolve rc-slider default export to fix SSR 500 - #751
Draft
dgaponov wants to merge 1 commit into
Draft
fix(slider): resolve rc-slider default export to fix SSR 500#751dgaponov wants to merge 1 commit into
dgaponov wants to merge 1 commit into
Conversation
/components/uikit/slider returned HTTP 500 in every locale, and was listed in sitemap.xml. It was the only non-200 among all 160 sitemap URLs. rc-slider resolves to its CJS build (`main: ./lib/index`) and ships no `exports` field. Combined with `esmExternals: 'loose'`, webpack handed uikit's `import Slider from 'rc-slider'` the module namespace object instead of the default export, so BaseSlider rendered an invalid element type and SSR threw "Element type is invalid ... but got: object". Alias rc-slider to its ESM build so the default import resolves to the component. rc-slider and rc-util also have to be bundled rather than left as ESM externals, otherwise Node cannot resolve their extensionless internal imports. Verified: slider returns 200 with full content in dev and in a production build, across en/ru/es/zh; other component, library and landing pages unaffected; build, lint and typecheck pass. E2E not run — Playwright browsers are not installed locally. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
dgaponov
force-pushed
the
seo/fix-slider-500
branch
from
September 8, 2026 09:06
c9e443b to
15bc393
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
/components/uikit/sliderотдавал 500 во всех локалях — единственный не-200 среди 160 URL sitemap.rc-sliderрезолвится в CJS-сборку без поляexports; вместе сesmExternals: 'loose'webpack отдавал uikit объект пространства имён вместо default-экспорта, и SSR падал наElement type is invalid. Алиас на ESM-сборку + бандлингrc-slider/rc-util(иначе Node не резолвит их внутренние импорты без расширений).Проверено: 200 с полным контентом в dev и prod, en/ru/es/zh; build, lint, typecheck, e2e — зелёные.
🤖 Generated with Claude Code