opensanctions / opensanctions/poliloom
Re-enable Turbopack once ::highlight() pseudo-element support is added
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 22
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Context
We are currently using webpack instead of Turbopack (Next.js 16's default bundler) because Turbopack's CSS parser (LightningCSS) does not yet support the ::highlight() pseudo-element, which we use for text highlighting in archived pages.
Current Workaround
Added --webpack flag to build and dev scripts in package.json to use webpack instead of Turbopack.
"dev": "next dev --webpack",
"build": "next build --webpack"
When to Re-enable Turbopack
Once the following upstream issues are resolved:
-
LightningCSS PR #970: Adds support for
::highlight()pseudo-element- https://github.com/parcel-bundler/lightningcss/pull/970
- Status: Pending review (as of Oct 2025)
-
Next.js Issue #85398: Tracks the
::highlight()parsing error in Turbopack- https://github.com/vercel/next.js/issues/85398
- Status: Open
Action Items
- Monitor LightningCSS PR #970 for merge
- Wait for Next.js to update its LightningCSS dependency
- Test build with Turbopack (remove
--webpackflags) - Remove webpack flags from package.json scripts once verified working
Related Code
- CSS usage:
src/app/globals.css(line 50) - Runtime usage:
src/lib/textHighlighter.ts - Injected styles:
src/app/api/archived-pages/[id]/html/route.ts
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the package.json dev and build scripts, then review the ::highlight() usage in src/app/globals.css, src/lib/textHighlighter.ts, and the archived-pages route. Check LightningCSS PR #970 and Next.js issue #85398 before testing without the --webpack flags. Done means Turbopack builds and runs successfully and the flags can be removed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css, javascript, next.js
- Domain
- build-system, frontend
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100