Skip to content

Commit

Permalink
fix: optimize SUSPENSE_REPLACE regex
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Jun 22, 2021
1 parent 7569fa2 commit fa32322
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/solid/src/static/rendering.ts
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ export function Suspense(props: { fallback: string; children: string }) {
return sharedConfig.context!.async ? { t: `<#${id}#>` } : props.fallback;
}

const SUSPENSE_REPLACE = /<#([0-9\.]+)\#>/;
const SUSPENSE_REPLACE = /<#([\d.]+)#>/;
export function awaitSuspense(fn: () => any) {
return new Promise(resolve => {
const registry = new Set<string>();
Expand Down

0 comments on commit fa32322

Please sign in to comment.