GithubHelp home page GithubHelp logo

citycoins2's Introduction

citycoins-ui-v2

Upgraded front-end for CityCoins.

Development

This repository uses React + Vite with:

To run locally:

npm install
npm start

Deployed via Cloudflare Pages.

citycoins2's People

Contributors

whoabuddy avatar

Watchers

Dan Trevino avatar  avatar

citycoins2's Issues

Store fetched data in local storage

The basic structure so far:

  • query atoms fetch data and provide status
  • hooks kicks off query, returns status based on query atom
  • localstorage atoms store results, written to by components

Components can respond to the loading values in the hook or the null localstorage constant.

Components should write the fetched data with useEffect().

Proposals accordion should allow multiple open

This should be a small change, mostly just noting it here. It'd be nice to be able to expand any proposal and leave it open, which helps if comparing information side-by-side. Each can still be closed by clicking its title.

Evaluate fetch options in hook

Each hook could return either the query atom or the local storage atom values.

Default would be local storage, pass parameter like update=true to force query.

Can set data same way a successful query would (hasData = true).

If local storage isn't found, use query atom and return.

Writing to the atoms still happens at the component level (or they can do whatever they want with the data at that point).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.