Patch Changes
-
74485ef: Add
utils
functions in theconfig:resolved
hook, making it easy to apply transformations after all
presets have been merged.For example, this could be used if you want to use most of a preset but want to completely omit a few things, while
keeping the rest. Let's say we want to remove thestack
pattern from the built-in@pandacss/preset-base
:import { defineConfig } from '@pandacss/dev' export default defineConfig({ // ... hooks: { 'config:resolved': ({ config, utils }) => { return utils.omit(config, ['patterns.stack']) }, }, })
-
ab32d1d: Introduce 3 new hooks:
tokens:created
This hook is called when the token engine has been created. You can use this hook to add your format token names and
variables.This is especially useful when migrating from other css-in-js libraries, like Stitches.
export default defineConfig({ // ... hooks: { 'tokens:created': ({ configure }) => { configure({ formatTokenName: (path) => '