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
゚ω゚ノ= /`m´)ノ ~┻━┻ //*´∇`*/ ["_"]; o=(゚ー゚) =_=3; c=(゚0゚) =(゚ー゚)-(゚ー゚); (゚Д゚) =(゚0゚)= (o^_^o)/ (o^_^o);(゚Д゚)={゚0゚: "_" ,゚ω゚ノ : ((゚ω゚ノ==3) +"_") [゚0゚] ,゚ー゚ノ :(゚ω゚ノ+ "_")[o^_^o -(゚0゚)] ,゚Д゚ノ:((゚ー゚==3) +"_")[゚ー゚] }; (゚Д゚) [゚0゚] =((゚ω゚ノ==3) +"_") [c^_^o];(゚Д゚) ["c"] = ((゚Д゚)+"_") [ (゚ー゚)+(゚ー゚)-(゚0゚) ];(゚Д゚) ["o"] = ((゚Д゚)+"_") [゚0゚];(゚o゚)=(゚Д゚) ["c"]+(゚Д゚) ["o"]+(゚ω゚ノ +"_")[゚0゚]+ ((゚ω゚ノ==3) +"_") [゚ー゚] + ((゚Д゚) +"_") [(゚ー゚)+(゚ー゚)]+ ((゚ー゚==3) +"_") [゚0゚]+((゚ー゚==3) +"_") [(゚ー゚) - (゚0゚)]+(゚Д゚) ["c"]+((゚Д゚)+"_") [(゚ー゚)+(゚ー゚)]+ (゚Д゚) ["o"]+((゚ー゚==3) +"_") [゚0゚];(゚Д゚) ["_"] =(o^_^o) [゚o゚] [゚o゚];(゚ε゚)=((゚ー゚==3) +"_") [゚0゚]+ (゚Д゚) .゚Д゚ノ+((゚Д゚)+"_") [(゚ー゚) + (゚ー゚)]+((゚ー゚==3) +"_") [o^_^o -゚0゚]+((゚ー゚==3) +"_") [゚0゚]+ (゚ω゚ノ +"_") [゚0゚]; (゚ー゚)+=(゚0゚); (゚Д゚)[゚ε゚]="\\"; (゚Д゚).゚0゚ノ=(゚Д゚+ ゚ー゚)[o^_^o -(゚0゚)];(o゚ー゚o)=(゚ω゚ノ +"_")[c^_^o];(゚Д゚) [゚o゚]="\'";(゚Д゚) ["_"] ( (゚Д゚) ["_"] (゚ε゚+(゚Д゚)[゚o゚]+ (゚Д゚)[゚ε゚]+(゚0゚)+ (゚ー゚)+ (o^_^o)+ (゚Д゚)[゚ε゚]+(゚0゚)+ ((゚ー゚) + (゚0゚))+ ((゚ー゚) + (o^_^o))+ (゚Д゚)[゚ε゚]+(゚0゚)+ ((゚ー゚) + (゚0゚))+ ((o^_^o) +(o^_ |
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 vm = require('vm'); | |
const sandbox = { | |
document: { | |
createTextNode: "function createTextNode() { [native code] }", | |
getElementById: "function getElementById() { [native code] }", | |
write: "function write() { [native code] }", | |
documentElement: { | |
getAttribute(attribute) { | |
return null; |
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 vm = require('vm'); | |
console.log(vm.runInNewContext('this.constructor.constructor("return process")().env')); |
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
handleSend = (chatMsg) => { | |
this.props.webrtc.shout('chat', chatMsg); | |
this.props.onSend(chatMsg); | |
} |
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 { LioWebRTC } from 'react-liowebrtc'; | |
import './App.css'; | |
import ChatBox from './ChatBox'; | |
class App extends Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
chatLog: [], |
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
join = (webrtc) => webrtc.joinRoom('my-p2p-app-demo'); | |
handleCreatedPeer = (webrtc, peer) => { | |
this.addChat(`Peer-${peer.id.substring(0, 5)} joined the room!`, ' ', true); | |
} | |
handlePeerData = (webrtc, type, payload, peer) => { | |
switch(type) { | |
case 'chat': | |
this.addChat(`Peer-${peer.id.substring(0, 5)}`, payload); |
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'; | |
class ChatBox extends Component { | |
render() { | |
return ( | |
<div> | |
<p>Hello world!</p> | |
</div> | |
); | |
} |
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 './App.css'; | |
import ChatBox from './ChatBox'; | |
class App extends Component { | |
render() { | |
return ( | |
<div className="App"> | |
<ChatBox /> | |
</div> |
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 './ChatBox.css'; | |
class ChatBox extends Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
inputMsg: '' | |
}; | |
} |
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
.container { | |
width: 500px; | |
max-width: 100%; | |
display: flex; | |
flex-flow: column; | |
margin: 10px auto; | |
border-radius: 5px; | |
padding: 0; | |
background-color: #383838; | |
border: 1px solid #333; |
NewerOlder