This file contains hidden or 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
| // App.js | |
| const App = () => | |
| <Context.Provider value={this.state.context}> | |
| <AppBar onPressLogoutButton={this.logout} /> | |
| <View style={{paddingTop: 64}}> | |
| <Router> | |
| <Route exact path="/" exact component={Home} /> | |
| </Router> | |
| </View> |
This file contains hidden or 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 from "react"; | |
| import firebase, { auth } from "src/firebase"; | |
| const App = () => { | |
| const [phoneNumber, setPhoneNumber] = React.useState(""); | |
| const [code, setCode] = React.useState(""); | |
| const [user, setUser] = React.useState(null); | |
| React.useEffect(() => { | |
| // ======= |
This file contains hidden or 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 from "react"; | |
| import { Modal } from "src/components"; | |
| const CrudPanel = ({ key, data, tableFields, entryFields, operations }) => { | |
| const [isModalVisible, setIsModalVisible] = React.useState(false); | |
| const openModal = () => setIsModalVisible(true); | |
| const closeModal = () => setIsModalVisible(false); | |
| return ( |
This file contains hidden or 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
| function getRecipeSchema(schema) { | |
| if(!schema) { | |
| const nodes = document.querySelectorAll('script[type="application/ld+json"]'); | |
| let returnData; | |
| nodes.forEach(n => { | |
| const childSchema = JSON.parse(n.innerText); | |
| const data = getRecipeSchema(childSchema); | |
| if(data) returnData = data; | |
| }); | |
| return returnData; |
OlderNewer