question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Types not working correctly

See original GitHub issue

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', {

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:15 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
Temzassecommented, Oct 23, 2021

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 🙂

1reaction
mtt87commented, Oct 20, 2021

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

Read more comments on GitHub >

github_iconTop Results From Across the Web

Typescript inference not working correctly - Stack Overflow
I'm trying to build a function that returns a typed object through a function that explicility is passed the type.
Read more >
Argument type infer not work correctly without specify ... - GitHub
Without specify state: State , the commits type infer in actions.a not correct. I suppose TS will infer what state is, and there...
Read more >
keyboard not working correctly type in J and get uyj type in d ...
I have checked the settings and the language is set correctly. I tried changing the usb port that the keyboard was plugged into....
Read more >
Documentation - Do's and Don'ts - TypeScript
Don't ever use the types Number , String , Boolean , Symbol , or Object These types refer to non-primitive boxed objects that...
Read more >
Fixing common type problems - Dart programming language
Fixing common type problems · error - A value of type 'int' can't be assigned to a variable of type 'bool'. · error...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found