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 fetchInitialData = () => { | |
return Promise.resolve({ | |
countries: [], | |
allowedCurrencies: [] | |
}); | |
}; | |
const submitPayment = () => { | |
return Promise.resolve({}); |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
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
func webView(_ webView: WKWebView, decidePolicyFor navigationAction: WKNavigationAction, decisionHandler: @escaping (WKNavigationActionPolicy) -> Void) { | |
if (openInDocumentPreview(navigationAction.request.url!)) { | |
decisionHandler(.cancel) | |
// TODO: Add more supported mime-types for missing content-disposition headers | |
webView.evaluateJavaScript(""" | |
(async function download() { | |
const url = '\(navigationAction.request.url!.absoluteString)'; | |
try { |
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
public void delete(Entity e) { | |
this.em.remove(em.find(Entity.class, e.getId())); | |
} |