Coder Social home page Coder Social logo

jaydenseric / react-waterfall-render Goto Github PK

View Code? Open in Web Editor NEW
6.0 3.0 0.0 114 KB

Renders nested React components with asynchronous cached loading; useful for GraphQL clients and server side rendering.

Home Page: https://npm.im/react-waterfall-render

JavaScript 100.00%
react graphql node hooks esm mjs maintained npm deno typescript

react-waterfall-render's Introduction

react-waterfall-render

Renders nested React components with asynchronous cached loading.

Useful for GraphQL clients (e.g. graphql-react) and server side rendering.

Installation

For Node.js, to install react-waterfall-render and its react peer dependency with npm, run:

npm install react-waterfall-render react

For Deno and browsers, an example import map (realistically use 4 import maps, with optimal URLs for server vs client and development vs production):

{
  "imports": {
    "react": "https://esm.sh/[email protected]",
    "react-waterfall-render/": "https://unpkg.com/[email protected]/"
  }
}

Use the WaterfallRenderContext in React components to declare asynchronous cached loading, and use the function waterfallRender to server side render your React app in a fully loaded state.

Requirements

Supported runtime environments:

  • Node.js versions ^14.17.0 || ^16.0.0 || >= 18.0.0.
  • Deno, importing from a CDN that might require an import map for dependencies.
  • Browsers matching the Browserslist query > 0.5%, not OperaMini all, not dead.

Non Deno projects must configure TypeScript to use types from the ECMAScript modules that have a // @ts-check comment:

Exports

The npm package react-waterfall-render features optimal JavaScript module design. It doesn’t have a main index module, so use deep imports from the ECMAScript modules that are exported via the package.json field exports:

react-waterfall-render's People

Contributors

jaydenseric avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

react-waterfall-render's Issues

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.