Following up on the issue initially reported in [0].
In [1], anchor URLs get processed to potentially fetch a model. The anchor chunk of the URL is kept when it should probably not be. This results in a regex not to perform well. But this is more a side effect. Stripping or ignoring the anchor chunk is probably the actual expectation. I such a case, we probably are interested in fetching the model of the page.
Describe the bug
Following up on the issue initially reported in [0].
In [1], anchor URLs get processed to potentially fetch a model. The anchor chunk of the URL is kept when it should probably not be. This results in a regex not to perform well. But this is more a side effect. Stripping or ignoring the anchor chunk is probably the actual expectation. I such a case, we probably are interested in fetching the model of the page.
[0] https://github.com/adobe/aem-angular-editable-components/issues/33 [1] https://github.com/adobe/aem-spa-page-model-manager/blob/3ea346c82a107cef310d37d738e267d895fe805a/src/PathUtils.ts#L245
Package version Provide a package version where the bug occurs.
To Reproduce Steps to reproduce the behavior:
Try to navigate to a URL of the SPA that contains an anchor chunk
e.g.
my-website/my-page#anchor
Experienced behavior
The following illegitimate URL is generated:
my-website/my-page#anchor.model
Expected behavior A clear and concise description of what you expected to happen.
The following URL should be generated instead
my-website/my-page.model
Screenshots If applicable, add screenshots to help explain your problem.
See: https://github.com/adobe/aem-angular-editable-components/issues/33
Additional context Add any other context about the problem here.