Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
145023da
Commit
145023da
authored
Sep 03, 2019
by
yann300
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use cors
parent
9e6f599f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
0 deletions
+3
-0
package.json
remix-simulator/package.json
+1
-0
server.js
remix-simulator/src/server.js
+2
-0
No files found.
remix-simulator/package.json
View file @
145023da
...
...
@@ -18,6 +18,7 @@
"body-parser"
:
"^1.18.2"
,
"color-support"
:
"^1.1.3"
,
"commander"
:
"^2.19.0"
,
"cors"
:
"^2.8.5"
,
"ethereumjs-util"
:
"^5.1.2"
,
"ethereumjs-vm"
:
"3.0.0"
,
"express"
:
"^4.16.3"
,
...
...
remix-simulator/src/server.js
View file @
145023da
const
express
=
require
(
'express'
)
const
cors
=
require
(
'cors'
)
const
bodyParser
=
require
(
'body-parser'
)
const
app
=
express
()
const
expressWs
=
require
(
'express-ws'
)
...
...
@@ -14,6 +15,7 @@ class Server {
start
(
host
,
port
)
{
expressWs
(
app
)
app
.
use
(
cors
())
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
true
}))
app
.
use
(
bodyParser
.
json
())
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment