Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/codingshot/boshacks


https://github.com/codingshot/boshacks

Last synced: about 1 month ago
JSON representation

Awesome Lists containing this project

README

        

# Browser

A framework for reusable components to render and modify SocialDB by Near Social.

## Setup & Development

Initialize repo:
```
yarn
```

Start development version:
```
yarn start
```

## Widget example

Profile view

```jsx
let accountId = props.accountId || "eugenethedream";
let profile = socialGetr(`${accountId}/profile`);

(



{profile.name} (@{accountId})

);
```

Profile editor

```jsx
let accountId = context.accountId;

if (!accountId) {
return "Please sign in with NEAR wallet";
}

const profile = socialGetr(`${accountId}/profile`);

if (profile === null) {
return "Loading";
}

initState({
name: profile.name,
url: profile.image.url,
});

const data = {
profile: {
name: state.name,
image: {
url: state.url,
},
},
};

return (


account = {accountId}


Name:



Image URL:


Preview


profile image {state.name}


Save profile


);

```