0.2.2 • Published 8 years ago
react-sandbox-frame v0.2.2
React Sandbox Frame
this package create an customizable and declarative iframe
usage
import React, { Component } from 'react'
import Frame from 'react-sandbox-frame'
export class WebView extends Component {
/**
* connect frame and you component
* @param {HTMLElement} document
*/
onLoad (document) {
console.log(document) // output <p>hello world</p>
}
render () {
return (
<Frame onLoad={this.onLoad.bind(this)}>
<p>hello world</p>
</Frame>
)
}
}Optional Props
The Frame component takes a couple of props that you can use to customize its behaviour:
children [?element]onLoad [?function]src [?string]style [?object]title [?string=page-wrapper]stylesheets [?Array<String>=[]]scripts [?Array<String>=[]]
0.2.2
8 years ago
0.2.1
8 years ago
0.2.0
8 years ago
0.1.1
8 years ago
0.1.0
8 years ago
0.0.21
9 years ago
0.0.20
9 years ago
0.0.18
9 years ago
0.0.18-0
9 years ago
0.0.17
9 years ago
0.0.16
9 years ago
0.0.15
9 years ago
0.0.14
9 years ago
0.0.13
9 years ago
0.0.12
9 years ago
0.0.11
9 years ago
0.0.10
9 years ago
0.0.9
9 years ago
0.0.8
9 years ago
0.0.7
9 years ago
0.0.6
9 years ago
0.0.5
9 years ago
0.0.4
9 years ago
0.0.3
9 years ago
0.0.2
9 years ago
0.0.1
9 years ago