File tree Expand file tree Collapse file tree 2 files changed +25
-0
lines changed
cypress/integration/default Expand file tree Collapse file tree 2 files changed +25
-0
lines changed Original file line number Diff line number Diff line change
1
+ describe ( 'appDir' , ( ) => {
2
+ it ( 'renders appdir pages using SSR' , ( ) => {
3
+ cy . request ( '/blog/erica/first-post/' ) . then ( ( response ) => {
4
+ expect ( response . headers ) . to . have . property ( 'x-nf-render-mode' , 'ssr' )
5
+ expect ( response . headers ) . to . have . property ( 'context-type' , 'text/html; charset=utf-8' )
6
+ } )
7
+ } )
8
+
9
+ it ( 'returns RSC data for RSC requests' , ( ) => {
10
+ cy . request ( '/blog/erica/first-post/' , {
11
+ Headers : {
12
+ RSC : '1' ,
13
+ } ,
14
+ } ) . then ( ( response ) => {
15
+ expect ( response . headers ) . to . have . property ( 'x-nf-render-mode' , 'ssr' )
16
+ expect ( response . headers ) . to . have . property ( 'context-type' , 'application/octet-stream' )
17
+ } )
18
+ } )
19
+ } )
Original file line number Diff line number Diff line change @@ -158,6 +158,12 @@ const Index = ({ shows, nodeEnv }) => {
158
158
< Link href = "/rewriteToStatic" > Rewrite to static (should show getStaticProps/1)</ Link >
159
159
</ li >
160
160
</ ul >
161
+ < h4 > appDir</ h4 >
162
+ < ul >
163
+ < li >
164
+ < Link href = "/blog/erica" > app dir page</ Link >
165
+ </ li >
166
+ </ ul >
161
167
< h4 > Preview mode</ h4 >
162
168
< p > Preview mode: </ p >
163
169
< ul >
You can’t perform that action at this time.
0 commit comments