In SSR context, this options sets client requests headers as default headers for the axios requests. debugĪdds interceptors that logs axios request and responses. That needs to pass authentication headers to the backend. You can also disable the progress bar in specific requests using the progress option in an inline request configuration:Īdds an interceptor that automatically sets withCredentials axios configuration when issuing a request to baseURL This is active only in the browser, and when loading bar is enabled and available. This option shows a loading bar while making requests integrating Nuxt.js progress bar (see "loading" options in ). If set to true, in both baseURL and browserBaseURL will be changed into progress WARNING: when the proxy option is enabled the default for browserBaseURL becomes prefix instead of baseURL. The environment variable API_URL_BROWSER can be used to override browserBaseURL. browserBaseURLĭefines the base URL which is used and prepended to make client side requests. WARNING: baseURL and proxy cannot be used at the same time, so when the proxy option is in use, you need to define prefix instead of baseURL. Default: Defines the base URL which is used and prepended to make server side requests.Įnvironment variable API_URL can be used to override baseURL.They can be customized with API_PREFIX, API_HOST (or HOST) and API_PORT (or PORT) environment variables. These options are used for the default values of baseURL and browserBaseURL. BaseURL : ', // Used as fallback if no runtime config is provided } ,īrowserBaseURL : process.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |