File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed
Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change 1+ <!doctype html>
2+ < html >
3+ < head >
4+ < title > storetest</ title >
5+ </ head >
6+ < body >
7+ < script type ="module ">
8+ import * as $rdf from "https://esm.sh/rdflib" ;
9+ import { store } from "https://esm.sh/solid-logic" ;
10+ async function testrun ( url ) {
11+ try {
12+ await store . fetcher . load ( url , { withCredentials :false } ) ;
13+ document . body . innerHTML += '<p>fetcher.load succeeded!</p>' ;
14+ }
15+ catch ( e ) { document . body . innerHTML += `<p>fetcher.load failed! ${ e } </p>` ; }
16+ try {
17+ await store . fetcher . webOperation ( 'GET' , url , { withCredentials :false } ) ;
18+ document . body . innerHTML += '<p>fetcher.webOperation succeeded!</p>' ;
19+ }
20+ catch ( e ) { document . body . innerHTML += `<p>fetcher.webOperation failed! ${ e } </p>` ; }
21+ }
22+ async function storetest ( url ) {
23+ try {
24+ await store . fetcher . load ( url , { withCredentials :false } ) ;
25+
26+ //code goes here
27+ //read name
28+ //read webid
29+ //read fn
30+ //read prefs
31+ //read public type index
32+ //read private type index
33+ //read storage
34+
35+ //display html
36+ //write output in public storage
37+
38+ document . body . innerHTML += '<p>end of store test function reached</p>' ;
39+ }
40+ catch ( e ) { document . body . innerHTML += `<p>store test function failed! ${ e } </p>` ; }
41+ }
42+ testrun ( 'https://solidweb.me/testpro-dev/profile/card#me' ) ;
43+ storetest ( 'https://solidweb.me/testpro-dev/profile/card#me' ) ;
44+ </ script >
45+ < p > content</ p >
46+ </ body >
47+ </ html >
You can’t perform that action at this time.
0 commit comments