stitches-native: Types not working correctly

EDIT: sorry I accidentally pressed enter and created the empty issue πŸ˜†

First of all thanks for creating this library, I’m testing it and I found this issue where types are not working. Screenshot 2021-10-20 at 13 54 51

It should suggest fontFamily, fontSize etc but it’s not

That said, once I write fontFamily: " then I get the correct autocomplete based on my tokens. Screenshot 2021-10-20 at 13 55 01

"react-native": "0.65.1",
"typescript": "^4.4.4"
"stitches-native": "^0.0.1-4"

EDIT: I just realised I can also do this but still the issue is there

import { Text as TextComponent } from 'react-native'
const Text = styled(TextComponent, {
// same as
const Text = styled('Text', {

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 15 (8 by maintainers)

Most upvoted comments

Another issue, negative token values don’t seem to work they are treated as positive.

const View = styled('View');

<View css={{ marginLeft: '$2' }}> 
<View css={{ marginLeft: '-$2' }}>

They both have the same output

This should be now fixed in v0.0.1-7 πŸ™‚

Another issue, negative token values don’t seem to work they are treated as positive.

const View = styled('View');

<View css={{ marginLeft: '$2' }}> 
<View css={{ marginLeft: '-$2' }}>

They both have the same output