Bug Report
Current behavior
Query parameter values are truncated at the second equals sign. On develop f34374b7423340e5ddec81c8ff565c26cc056fb5, parseQuery('?id=a=b=c&other=ok') returns {id: 'a', other: 'ok'} instead of preserving a=b=c.
The same parser is used by both hash and HTML5 history, so route queries exposed to plugins are affected. Values containing a literal equals sign, including padded encoded data, lose information.
Reproduction
From the source checkout:
import { parseQuery } from './src/core/router/util.js';
console.log(parseQuery('?id=a=b=c&other=ok'));
// { id: 'a', other: 'ok' }
Expected behavior
Only the first equals sign separates the parameter name from its value. Remaining equals signs should stay in the value. Existing decoding, plus-to-space conversion, empty values and valueless parameters should retain their behavior.
Environment
Docsify 5.0.0 develop source, Node.js on macOS. Reproduced directly and with a failing Jest regression in the existing router utility suite.
Bug Report
Current behavior
Query parameter values are truncated at the second equals sign. On develop
f34374b7423340e5ddec81c8ff565c26cc056fb5,parseQuery('?id=a=b=c&other=ok')returns{id: 'a', other: 'ok'}instead of preservinga=b=c.The same parser is used by both hash and HTML5 history, so route queries exposed to plugins are affected. Values containing a literal equals sign, including padded encoded data, lose information.
Reproduction
From the source checkout:
Expected behavior
Only the first equals sign separates the parameter name from its value. Remaining equals signs should stay in the value. Existing decoding, plus-to-space conversion, empty values and valueless parameters should retain their behavior.
Environment
Docsify 5.0.0 develop source, Node.js on macOS. Reproduced directly and with a failing Jest regression in the existing router utility suite.