@@ -43,7 +43,7 @@ The following is the definition of the `router` object returned by both [`useRou
-`pathname`: `String` - Current route. That is the path of the page in `/pages`
-`query`: `Object` - The query string parsed to an object. It will be an empty object during prerendering if the page doesn't have [data fetching requirements](/docs/basic-features/data-fetching.md). Defaults to `{}`
-`asPath`: `String` - Actual path (including the query) shown in the browser.
-`asPath`: `String` - The path (including the query) shown in the browser without the configured `basePath` or `locale`.
-`isFallback`: `boolean` - Whether the current page is in [fallback mode](/docs/basic-features/data-fetching#fallback-pages).
-`basePath`: `String` - The active [basePath](/docs/api-reference/next.config.js/basepath)(if enabled).
-`locale`: `String` - The active locale (if enabled).
`Failed to parse src "${src}" on \`next/image\`, protocol-relative URL (//) must be changed to an absolute URL (http:// or https://)`
)
}
if(!src.startsWith('/')&&configDomains){
letparsedSrc:URL
try{
parsedSrc=newURL(src)
}catch(err){
console.error(err)
thrownewError(
`Failed to parse "${src}" in "next/image", if using relative image it must start with a leading slash "/" or be an absolute URL (http:// or https://)`
`Failed to parse src "${src}" on \`next/image\`, if using relative image it must start with a leading slash "/" or be an absolute URL (http:// or https://)`
'Failed to parse src "//assets.example.com/img.jpg" on `next/image`, protocol-relative URL (//) must be changed to an absolute URL (http:// or https://)'