diff --git a/CHANGELOG.md b/CHANGELOG.md index 67227fb4a..7a2c6fa1b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## Unreleased + +- Fix creation sentry example when no routes folder ([#680](https://github.com/getsentry/sentry-wizard/pull/680)) + ## 3.32.0 - feat: Add `--saas` CLI arg to skip self-hosted or SaaS selection step (#678) diff --git a/src/remix/sdk-example.ts b/src/remix/sdk-example.ts index cbdfec643..2c3a5a433 100644 --- a/src/remix/sdk-example.ts +++ b/src/remix/sdk-example.ts @@ -13,6 +13,12 @@ export async function createExamplePage(options: { url: string; isTS: boolean; }) { + const routesPath = 'app/routes'; + + if (!fs.existsSync(routesPath)) { + fs.mkdirSync(routesPath); + } + const exampleRoutePath = `app/routes/sentry-example-page.${ options.isTS ? 'ts' : 'js' }x`;