What exactly do you mean by VS Code not recognizing you config file? I copied your config file into an app and got your blue theme displaying fine. (You are missing a hashtag on one of your hex colors, but that didnāt cause a parsing issue for me in Streamlit 1.21.0 at least.) It appears your files are named correctly and save correctly in relation to each other. If this was a deployed app on Streamlit Cloud, Iād advise you to reboot your app since updates to the config file may not reflect after the app is already running.
However, I use VS Code too, and Iāve never had trouble updating theme colors on the fly. I suppose your first try to should be to double check everything is saved then close your terminal and relaunch your app to be sure. Also, make sure you havenāt selected anything from the hamburger menu in the upper right to override the theme.
Have you tried any other browsers to confirm if it consistent elsewhere?
āWhat exactly do you mean by VS Code not recognizing you config file?ā
I mean, my file didnāt get colored, you know? It looks like a simple .txt.
My .CSS file is like this:
And my .toml is like this:
Vscode isnāt recognizing the file?
Thereās a config that I supposed to do before using .TOML?
If you tried my code and got it, the problem is my pc.
I tried to relaunch everything, but It didināt work.
I was watching a tutorial about this one and the teacher just created the file out of vscode, in the folder. I tried doing this but didnāt work. He did this steps:
Right click > new > new text document and renamed the file to config.toml and got this:
When I did the same thing, got this:
it remains as .txt, so I created inside VSCODE and got this:
It changed from text document to toml font.
So I think my windowns need a config to accept TOML files, you know? Because Iām importing others files to use, animation, style, pictures and It is working fine.
I see. Thatās a VSCode configuration issue rather than anything to do with Streamlit.
It looks like there is no way to natively do that for toml files, so you will have to install an extension. It is discussed here with an option is given:
I installed the extension and it works, now thereās color in .toml.
I downloaded all files from the yt video to make sure thatās something wrong with my windows and runned the his āapp.pyā and didnāt work as well.
So, thereās a problem with my PC.
I think thereās nothing to do from here, so, thanks yāall.
Thanks for stopping by! We use cookies to help us understand how you interact with our website.
By clicking āAccept allā, you consent to our use of cookies. For more information, please see our privacy policy.
Cookie settings
Strictly necessary cookies
These cookies are necessary for the website to function and cannot be switched off. They are usually only set in response to actions made by you which amount to a request for services, such as setting your privacy preferences, logging in or filling in forms.
Performance cookies
These cookies allow us to count visits and traffic sources so we can measure and improve the performance of our site. They help us understand how visitors move around the site and which pages are most frequently visited.
Functional cookies
These cookies are used to record your choices and settings, maintain your preferences over time and recognize you when you return to our website. These cookies help us to personalize our content for you and remember your preferences.
Targeting cookies
These cookies may be deployed to our site by our advertising partners to build a profile of your interest and provide you with content that is relevant to you, including showing you relevant ads on other websites.