Skip to content

Commit

Permalink
Forward headers
Browse files Browse the repository at this point in the history
  • Loading branch information
RobertBroersma committed Nov 27, 2023
1 parent 2538590 commit ce8df19
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
1 change: 0 additions & 1 deletion app/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ export default defineNuxtConfig({
public: {
stacRoot: process.env.NUXT_STAC_ROOT,
mapboxToken: process.env.NUXT_PUBLIC_MAPBOX_TOKEN,
password: process.env.NUXT_PUBLIC_PASSWORD,
},
},
css: ['vuetify/styles'],
Expand Down
8 changes: 4 additions & 4 deletions app/pages/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ let baseURL = url.protocol + '//' + url.host + '/stac'
let catalogPath = `${baseURL}/catalog.json`
console.log('password', btoa(password))
let headers = useRequestHeaders()
console.log({ headers })
let { data: catalogJson } = await useFetch<CatalogType>(catalogPath, {
headers: {
Authorization: `Basic ${btoa(password)}`,
},
headers,
})
let catalog = catalogJson.value
Expand Down

0 comments on commit ce8df19

Please sign in to comment.