Skip to content
Discussion options

You must be logged in to vote

Sorry, I misread your question above.

This is a case in which I need to look through the source code to find the answer, so I'm going to do that, and paste in what I find, so you can see how I did that.

Searching in the Leptos repo for LEPTOS_ENV brings me to leptos_config/src/lib.rs and to the default initialization of a field in the definition of a struct called LeptosOptions

env: env_from_str(env_w_default("LEPTOS_ENV", "DEV")?.as_str())?,

Ok, so the struct field is named env and the environment variable is LEPTOS_ENV.

I'm curious what the type of env is, so I scroll up and see that it's... Env

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@saikatdas0790
Comment options

@saikatdas0790
Comment options

@gbj
Comment options

gbj Nov 15, 2023
Maintainer

Answer selected by saikatdas0790
@saikatdas0790
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants