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 { injectManifest, InjectManifestConfig, copyWorkboxLibraries } = require('workbox-build') | |
const rimraf = require('rimraf') | |
const { convertCompilerOptionsFromJson } = require('typescript') | |
const prependFile = require('prepend-file') | |
const { isNil } = require('ramda') | |
const { isEmpty } = require('ramda') | |
const { map } = require('ramda') | |
/** | |
* Injects the Manifest for the Service worker |
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
{ | |
statement: { | |
id: bafy2bzacecs6xmdosu7utcb4gjqdmjq6qxw4w63prqdtstz3yj2ucnxuxpswu, | |
data: { | |
signatures: { | |
holder: { | |
sigKey: urn:pgp:5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY, | |
sig: 0xae43651d482f10f75cac09a75834f9ac04f79f0e4b43ba37b8f047d19a3836533b7705f885ee58bf0e2d0b3989f122151d19121060147739ba70c42603a7f58c, | |
cid: bafy2bzacebrqcepjfdcfqqvh4n7qszffzwt63pc67orgiyx6emzpi7jy2dfdk | |
}, |
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 IPFS = require("ipfs"); | |
const OrbitDB = require("orbit-db"); | |
// Create the first peer | |
async function main() { | |
try { | |
const ipfs1 = await IPFS.create({ | |
repo: "./test/ipfs1", | |
init: { | |
emptyRepo: true, | |
}, |
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
[color] | |
ui = true | |
[color "branch"] | |
current = yellow reverse | |
local = yellow | |
remote = green | |
[color "diff"] | |
meta = yellow bold | |
frag = magenta bold | |
old = red |
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
! Compiling of exercises/traits/traits2.rs failed! Please try again. Here's the output: | |
error[E0308]: mismatched types | |
--> exercises/traits/traits2.rs:21:9 | |
| | |
19 | fn append_bar(&mut self) -> Self { | |
| ---- expected `std::vec::Vec<std::string::String>` because of return type | |
20 | self.push(String::from("Bar")); | |
21 | self | |
| ^^^^ |
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
! Compiling of exercises/traits/traits2.rs failed! Please try again. Here's the output: | |
error[E0308]: mismatched types | |
--> exercises/traits/traits2.rs:21:9 | |
| | |
19 | fn append_bar(&mut self) -> Self { | |
| ---- expected `std::vec::Vec<std::string::String>` because of return type | |
20 | self.push(String::from("Bar")); | |
21 | self | |
| ^^^^ |
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
use frame_support::{decl_module, decl_storage, decl_event, dispatch::DispatchResult, ensure, StorageMap}; | |
use system::ensure_signed; | |
use serde::{Serialize, Deserialize}; | |
use serde_json::json; | |
use sp_runtime::print; | |
use sp_std::vec::Vec; |
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
└─❱❱❱ curl -v https://runkit.com/home 6 ⏎ +1736 9:27 ❰─┘ * Could not resolve host: runkit.com | |
* Closing connection 0 | |
curl: (6) Could not resolve host: runkit.com |
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
interface copyright { | |
holder: string; | |
issuer: string; | |
subject: string; | |
proportion: { | |
value: number; | |
type: string; | |
sign: string; | |
}; | |
payload: string; |
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
var flattenObject = function(ob) { | |
var toReturn = {}; | |
for (var i in ob) { | |
if (!ob.hasOwnProperty(i)) continue; | |
if ((typeof ob[i]) == 'object') { | |
var flatObject = flattenObject(ob[i]); | |
for (var x in flatObject) { | |
if (!flatObject.hasOwnProperty(x)) continue; |