Skip to content

Commit

Permalink
Update README.md to get exportedTokens in sync style
Browse files Browse the repository at this point in the history
  • Loading branch information
nvh95 committed Apr 12, 2022
1 parent 90140f1 commit c4dc878
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,14 @@ const css = `
`

let exportedTokens = {}
const styles = postcss([
const result = postcss([
CSSModulesSync({
generateScopedName: '[path][local]-[hash:base64:10]',
getJSON: tokens => exportedTokens = tokens
})
]).process(css).css
]).process(css)

console.log('styles', styles)
console.log('styles', result.css)
result.sync()
console.log('tokens', exportedTokens)
```

0 comments on commit c4dc878

Please sign in to comment.