Skip to content

EXUI-4216: cgi_ISSUE-035-rpx-xui-manage-organisations-unsafe-eval-csp#2190

Open
chrisjones-hmcts wants to merge 10 commits into
masterfrom
exui-4216-unsafe-eval-csp
Open

EXUI-4216: cgi_ISSUE-035-rpx-xui-manage-organisations-unsafe-eval-csp#2190
chrisjones-hmcts wants to merge 10 commits into
masterfrom
exui-4216-unsafe-eval-csp

Conversation

@chrisjones-hmcts

@chrisjones-hmcts chrisjones-hmcts commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

JIRA link (if applicable)

EXUI-4216

Change description

Replaces deprecated PEG.js package with the latest version of its successor peggy and generates the runtime parser from it during the build instead of generating it inline at runtime which is blocked by the MC update to our CSP (remove unsafe eval).

MC PR: hmcts/rpx-xui-webapp#5070

  • Added a Peggy grammar source file for the conditional parser.
  • Added script to generate condition-parser.generated.ts from the grammar source file.
  • Updated condition.peg.ts to import the generated parser instead of generating it inline at runtime.
  • Updated the library build so the parser is generated before ng build.
  • Moved peggy into devDependencies since it is now only needed at build time.

Does this PR introduce a breaking change? (check one with "x")

[ ] Yes
[x] No

@chrisjones-hmcts chrisjones-hmcts marked this pull request as ready for review June 24, 2026 13:16
@chrisjones-hmcts chrisjones-hmcts requested a review from a team as a code owner June 24, 2026 13:16

@connorpgpmcelroy connorpgpmcelroy left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unsure what change involves directly but looks OK to me. Was going to suggest comments in the first file but then said not to edit the code as was a generated file so not an option

olusegz07
olusegz07 previously approved these changes Jun 29, 2026
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants