How can I resolve the polaris dependency error while installing discount-app-components?

I’m trying to install @Shopify_77 /discount-app-components in an app following this tutorial https://shopify.dev/docs/apps/selling-strategies/discounts/experience/ui#what-youll-learn (step 2) but I’m receiving an error that the wrong version of polaris is installed (10.49.1) (requires 11.2.2).

I’m not sure if the error is within my app or the discount-app-components package or how I upgrade the app to polaris 11.2.2

Solved, I had to update react and polaris within the /web/frontend directory of the app this the following commands:

npm install react@latest react-dom@latest
npm install @Shopify_77 /polaris@^11.2.2
npm install @Shopify_77 /discount-app-components