File tree 4 files changed +11
-19
lines changed
4 files changed +11
-19
lines changed Original file line number Diff line number Diff line change 7
7
"jest:watch" : " npm run jest -- --watch --no-cache" ,
8
8
"test" : " mocha --reporter spec __tests__/**/*.test.js" ,
9
9
"test:watch" : " npm run test -- --watch" ,
10
- "dev" : " next -r dotenv/config " ,
10
+ "dev" : " next" ,
11
11
"build" : " next build" ,
12
12
"watch" : " nodemon server.js -w server.js" ,
13
13
"start" : " next start -p $PORT" ,
Original file line number Diff line number Diff line change @@ -8,15 +8,6 @@ import defaultPage from '../hocs/defaultPage'
8
8
import styled from 'styled-components'
9
9
import TodoInput from '../components/todo/todoInput'
10
10
import { injectGlobal } from 'styled-components' ;
11
- let env = process . env . NODE_ENV || 'development'
12
- const CLIENT_ID = ( env === 'production' ) ? process . env . AUTH0_CLIENT_ID : config . AUTH0_CLIENT_ID
13
- console . log ( CLIENT_ID )
14
- console . log ( typeof CLIENT_ID )
15
- injectGlobal `
16
- body {
17
- margin: 0;
18
- }
19
- ` ;
20
11
21
12
// const rule1 = {
22
13
// backgroundColor: 'blue',
@@ -35,6 +26,7 @@ injectGlobal`
35
26
// font-size:18px;
36
27
// }
37
28
// `
29
+
38
30
const Title = styled . h1 `${ {
39
31
color : 'red' ,
40
32
fontSize : '50px' ,
Original file line number Diff line number Diff line change @@ -19,6 +19,13 @@ app.prepare()
19
19
20
20
expressServer . get ( '/other' , ( req , res ) => {
21
21
// console.log(serverLock.getBaseUrl(req));
22
+
23
+
24
+ req . query = {
25
+ text : "spencer"
26
+ }
27
+
28
+ console . log ( req . query )
22
29
return app . render ( req , res , '/other' , req . query )
23
30
} )
24
31
@@ -27,6 +34,7 @@ app.prepare()
27
34
// console.log(JSON.stringify(req.secure, null, 2));
28
35
// console.log('headers'.red);
29
36
// console.log(JSON.stringify(req.headers, null, 2));
37
+
30
38
return app . render ( req , res , '/' , req . query )
31
39
} )
32
40
Original file line number Diff line number Diff line change 1
- let env = process . env . NODE_ENV || 'development'
2
1
3
2
const getLock = ( options ) => {
4
3
const config = require ( '../config.json' )
5
4
const Auth0Lock = require ( 'auth0-lock' ) . default
6
5
7
- // if(env === 'development' || env === 'test'){
8
- // return new Auth0Lock(config.AUTH0_CLIENT_ID, config.AUTH0_CLIENT_DOMAIN, options)
9
- // }
10
-
11
- const CLIENT_ID = ( env === 'production' ) ? process . env . AUTH0_CLIENT_ID : config . AUTH0_CLIENT_ID
12
- const DOMAIN = ( env === 'production' ) ? process . env . AUTH0_DOMAIN : config . AUTH0_CLIENT_ID
13
- // return new Auth0Lock(AUTH0_CLIENT_ID, AUTH0_CLIENT_DOMAIN, options)
14
- return new Auth0Lock ( CLIENT_ID , DOMAIN , options )
6
+ return new Auth0Lock ( config . AUTH0_CLIENT_ID , config . AUTH0_CLIENT_DOMAIN , options )
15
7
}
16
8
17
9
const getBaseUrl = ( ) => `${ window . location . protocol } //${ window . location . host } `
You can’t perform that action at this time.
0 commit comments