Skip to content

Commit ec7e9b2

Browse files
committed
fix(scheduler+ssr): correct order and draining
1 parent a052f8f commit ec7e9b2

File tree

10 files changed

+214
-295
lines changed

10 files changed

+214
-295
lines changed

packages/qwik/src/core/shared/error/error.ts

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export const codeToText = (code: number, ...parts: any[]): string => {
77
const MAP = [
88
'Error while serializing class or style attributes', // 0
99
'Scheduler not found', // 1
10-
'', // 2 unused
10+
'track() received object, without prop to track', // 2
1111
'Only primitive and object literals can be serialized. {{0}}', // 3
1212
'', // 4 unused
1313
'You can render over a existing q:container. Skipping render().', // 5
@@ -50,12 +50,11 @@ export const codeToText = (code: number, ...parts: any[]): string => {
5050
"Element must have 'q:container' attribute.", // 42
5151
'Unknown vnode type {{0}}.', // 43
5252
'Materialize error: missing element: {{0}} {{1}} {{2}}', // 44
53-
'Cannot coerce a Signal, use `.value` instead', // 46
54-
'useComputedSignal$ QRL {{0}} {{1}} returned a Promise', // 47
55-
'ComputedSignal is read-only', // 48
56-
'WrappedSignal is read-only', // 49
57-
'SsrError: Promises not expected here.', // 50
58-
'Attribute value is unsafe for SSR', // 51
53+
'Cannot coerce a Signal, use `.value` instead', // 45
54+
'useComputedSignal$ QRL {{0}} {{1}} returned a Promise', // 46
55+
'ComputedSignal is read-only', // 47
56+
'WrappedSignal is read-only', // 48
57+
'Attribute value is unsafe for SSR', // 49
5958
];
6059
let text = MAP[code] ?? '';
6160
if (parts.length) {
@@ -77,7 +76,7 @@ export const codeToText = (code: number, ...parts: any[]): string => {
7776
export const enum QError {
7877
stringifyClassOrStyle = 0,
7978
schedulerNotFound = 1,
80-
UNUSED_2 = 2,
79+
trackObjectWithoutProp = 2,
8180
verifySerializable = 3,
8281
UNUSED_4 = 4,
8382
cannotRenderOverExistingContainer = 5,
@@ -124,8 +123,7 @@ export const enum QError {
124123
computedNotSync = 46,
125124
computedReadOnly = 47,
126125
wrappedReadOnly = 48,
127-
promisesNotExpected = 49,
128-
unsafeAttr = 50,
126+
unsafeAttr = 49,
129127
}
130128

131129
export const qError = (code: number, errorMessageArgs: any[] = []): Error => {

0 commit comments

Comments
 (0)