mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
* Add export const config support and make withAmp a no-op * Use babel plugin for PageConfig * Fix serverless-loader exports * Add backwards compatibility for withAmp
9 lines
171 B
JavaScript
9 lines
171 B
JavaScript
import { useAmp } from 'next/amp'
|
|
|
|
export const config = { amp: 'hybrid' }
|
|
|
|
export default () => {
|
|
const isAmp = useAmp()
|
|
return `Hello ${isAmp ? 'AMP' : 'others'}`
|
|
}
|