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 { FlowRouter } from "meteor/kadira:flow-router"; | |
| Meteor.startup(function () { | |
| if (Meteor.isCordova) { | |
| universalLinks.subscribe("shareEvent", function (eventData) { | |
| const shareParameters = eventData.path.split("/share")[1]; | |
| alert(`shareEvent: ${JSON.stringify(eventData)}`); // just to check event data - should be removed | |
| if (shareParameters) { | |
| const linkToOpen = `/share${shareParameters}`; |
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.appendToConfig(` | |
| <edit-config file="app/src/main/AndroidManifest.xml" mode="merge" target="/manifest/application" xmlns:android="http://schemas.android.com/apk/res/android"> | |
| <application android:usesCleartextTraffic="true"></application> | |
| </edit-config> | |
| `); | |
| App.appendToConfig(` | |
| <universal-links> | |
| <host name="yourwebsite.com" scheme="https"> |
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"; | |
| const ParagraphSpans = function (spans) { | |
| return ( | |
| <React.Fragment> | |
| {spans.map((spanLabel) => ( | |
| <span>{spanLabel}</span> | |
| ))} | |
| </React.Fragment> | |
| ); |
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"; | |
| const FunctionalContentComponent = function (props) { | |
| return ( | |
| <body> | |
| {props.list.map(({ title, paragraph }, index) => ( | |
| <React.Fragment key={index}> | |
| <h1>{title} </h1> | |
| <p>{paragraph}</p> | |
| </React.Fragment> |
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, { Component } from "react"; | |
| class UncontrolledComponent extends Component { | |
| constructor(props) { | |
| super(props); | |
| this.inputRef = React.createRef(); | |
| } | |
| render() { | |
| 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
| import React, { Component } from "react"; | |
| class ControlledComponent extends Component { | |
| constructor(props) { | |
| super(props); | |
| this.state = { | |
| text: "" | |
| }; | |
| } |
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
| { | |
| "name": "retest", | |
| "short_name": "RT", | |
| "background_color": "#ffffff", | |
| "description": "A description about app.", | |
| "display": "standalone", | |
| "theme_color": "#ffffff", | |
| "crossorigin": "use-credentials", | |
| "start_url": "/index.html", | |
| "icons": [{ |
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
| const staticAssets = [ | |
| './', | |
| './styles.css', | |
| './app.js' | |
| ]; | |
| self.addEventListener('install', async event => { | |
| const cache = await caches.open('static-meme'); | |
| // cache.addAll(staticAssets); | |
| }); |
NewerOlder