Skip to content

Releases: wasp-lang/wasp

v0.16.0

29 Jan 16:25
Compare
Choose a tag to compare

🎉 New Features and improvements

Env variables validation with Zod

Wasp now uses Zod to validate environment variables, allowing it to fail faster if something is misconfigured. This means you’ll get more relevant error messages when running your app with incorrect env variables.

You can also use Zod to validate your own environment variables. Here’s an example:

// src/env.ts
import * as z from 'zod'

import { defineEnvValidationSchema } from 'wasp/env'

export const serverEnvValidationSchema = defineEnvValidationSchema(
  z.object({
    STRIPE_API_KEY: z.string({
      required_error: 'STRIPE_API_KEY is required.',
    }),
  })
)

// main.wasp
app myApp {
  ...
  server: {
    envValidationSchema: import { serverEnvValidationSchema } from "@src/env",
  },
}

Deployment docs upgrade

Based on feedback from our Discord community, we’ve revamped our deployment docs to make it simpler to deploy your app to production. We focused on explaining key deployment concepts, regardless of the deployment method you choose. We’ve added guides on hosting Wasp apps on your own servers, for example, how to use Coolify and Caprover for self-hosting. The Env Variables section now includes a comprehensive list of all available Wasp env variables and provides clearer instructions on how to set them up in a deployed app.

Check the updated deployment docs here: https://wasp-lang.dev/docs/deployment/intro

⚠️ Breaking Changes

  • Renamed and split deserializeAndSanitizeProviderData to getProviderData and getProviderDataWithPassword so it's more explicit if the resulting data will contain the hashed password or not.
  • You need to include react-dom and react-router-dom as deps in your package.json file. This ensures npm doesn't accidentally install React 19, which is not yet supported by Wasp:
    {
      // ...
      "dependencies": {
        // ...
        "react-dom": "^18.2.0",
        "react-router-dom": "^6.26.2"
      }
    }
  • Wasp now internally works with project references, so you'll have to update your tsconfig.json (Wasp will validate your tsconfig.json and warn you if you forget this). Here are all the properties you must set or change:
    {
      "compilerOptions": {
        // ...
        "composite": true,
        "skipLibCheck": true,
        "outDir": ".wasp/out/user"
      },
      "include": [
        "src"
      ]
    }

Read more about breaking changes in the migration guide: https://wasp-lang.dev/docs/migration-guides/migrate-from-0-15-to-0-16

🐞 Bug fixes

  • We fixed Fly deployment using the Wasp CLI where the server app PORT was set incorrectly.

🔧 Small improvements

  • Enabled strict null checks for the Wasp SDK which means that some of the return types are more precise now e.g. you'll need to check if some value is null before using it.
  • Documentation improvements and fixes.

Big thanks to our community members who contributed to this release! @Bojun-Feng @dabrorius @komyg @NathanaelA @vblazenka @Genyus

v0.16.0-rc2

24 Jan 16:02
d91b412
Compare
Choose a tag to compare
v0.16.0-rc2 Pre-release
Pre-release
Make Wasp TS Config projects work with project references (#2461)

v0.16.0-rc1

20 Jan 11:05
Compare
Choose a tag to compare
v0.16.0-rc1 Pre-release
Pre-release
Update headless tests for 0.16.0

v0.15.2

19 Nov 19:53
Compare
Choose a tag to compare

0.15.2

🐞 Bug fixes

  • Fixed build step for apps that use Wasp's new TS config.

v0.15.2-rc

19 Nov 19:11
Compare
Choose a tag to compare
v0.15.2-rc Pre-release
Pre-release
Merge branch 'release'

v0.15.1

21 Oct 23:26
Compare
Choose a tag to compare

🐞 Bug fixes

  • Server and Client setup props are no longer mandatory when using TS Config.

v0.15.0

10 Oct 18:00
Compare
Choose a tag to compare

0.15.0

🎉 New Features and improvements

Write your app config in TypeScript (preview feature)

Wasp 0.15.0 ships a preview feature that lets you define your app in main.wasp.ts using TypeScript instead of in main.wasp using the Wasp DSL.

So, instead of this:

app TodoApp {
  wasp: {
    version: "^0.15.0"
  },
  title: "TodoApp",
  auth: {
    userEntity: User,
    methods: {
      usernameAndPassword: {}
    },
    onAuthFailedRedirectTo: "/login"
  }
}

route RootRoute { path: "/", to: MainPage }
page MainPage {
  authRequired: true,
  component: import { MainPage } from "@src/MainPage"
}

You can now write this:

improt { App } from 'wasp-config'

const app = new App('TodoApp', {
  wasp: {
    version: '^0.15.0',
  },
  title: 'TodoApp',
})

app.auth({
  userEntity: 'User',
  methods: {
    usernameAndPassword: {}
  },
  onAuthFailedRedirectTo: '/login',
})

const mainPage = app.page('MainPage', {
  authRequired: true,
  component: { import: 'MainPage', from: '@src/MainPage' },
})
app.route('RootRoute', { path: '/', to: mainPage })

To learn more about this feature and how to activate it, check out the Wasp TS config docs.

⚠️ Breaking Changes

There are some breaking changes with React Router 6 which will require you to update your code.
Also, the new version of Prisma may cause breaking changes depending on how you're using it.

Read more about breaking changes in the migration guide: https://wasp-lang.dev/docs/migration-guides/migrate-from-0-14-to-0-15 .

🐞 Bug fixes

  • Allow setting a custom server URL when deploying to Fly.io. (by @Case-E)
  • If the user uses native DB types for the userEntity, Wasp will use them correctly.

🔧 Small improvements

  • Upgrade to the latest Prisma version which makes Wasp faster!
  • Upgrade to the latest React Router version which sets us up for some cool new features in the future.
  • Enable users to use Mailgun's EU region by setting the MAILGUN_API_URL env variable.
  • Validate userEntity ID field's @default attribute.

Community contributions by @Case-E @therumbler

v0.15.0-rc2

10 Oct 09:20
e92cb25
Compare
Choose a tag to compare

v0.15.0-rc1

04 Oct 12:07
05dfcc8
Compare
Choose a tag to compare
v0.15.0-rc1 Pre-release
Pre-release

v0.14.2

09 Sep 17:39
Compare
Choose a tag to compare

Updated GPT models used in Wasp AI to latest models, since 3.5 are getting deprecated.

Default model used is now 4o (instead of old 4 + 3.5-turbo combo).