This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
var formidable = require('formidable'); | |
var MongoClient = require('mongodb').MongoClient; | |
var assert = require('assert'); | |
var ObjectID = require('mongodb').ObjectID; | |
const express = require('express') | |
const app = express() | |
const mongourl = process.env.MONGOURL || "mongodb://developer:developer123@ds143593.mlab.com:43593/herbert1228"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require("express") | |
const app = express() | |
// const bodyParser = require("body-parser") | |
const session = require("express-session") | |
const uuid = require("uuid/v4") | |
const MongoClient = require("mongodb").MongoClient | |
const ObjectID = require("mongodb").ObjectID | |
const assert = require("assert") | |
const fs = require("fs") | |
const formidableMiddleware = require("express-formidable") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import {connection} from './interface/connection' | |
const style = { | |
canvas: { | |
style: { | |
left: '0px', | |
top: '0px' | |
}, | |
border: 'solid 1px', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import {connection} from './interface/connection' | |
export default class App extends React.Component { | |
state = { | |
counter: 0 | |
} | |
componentDidMount() { | |
connection.connect("ws://localhost:8500") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import {connection} from './interface/connection' | |
export default class App extends React.Component { | |
state = { | |
counter: 0 | |
} | |
componentDidMount() { | |
connection.connect("ws://localhost:8500") |