Observed since 20 Oct, 18:54 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
2021ai-grace-app
Use this package to build your React app to work in Grace environment.
Use this package to build your React app to work in Grace environment.
Install 2021ai-grace-app in your project:
yarn add 2021ai-grace-app
Make sure you have peer dependencies installed in your project:
"axios": "^1.4.0",
"react": "^18.2.0"
Make sure to have src/App.jsx file, which exports a React component called App.
2021ai-grace-app serve to run app your app in development mode
2021ai-grace-app build to build your app to production
Grace app loads a config file in run-time. The config.json file is expected to be located in the parent directory
relative to grace-app. Currently following properties are defined:
apiPath - the url pointing to client's application backend APIIn your React app you can use:
useGraceContext - a hook that would return following object:
{
config: {
apiPath: string
}
}
example:
const { config } = useGraceContext();
console.log(config.apiPath);
The library comes with some default webpack configs, which are used when serving or building the app
with 2021ai-grace-app CLI commands. These configs provide basic support for react apps. If your project requires
additional webpack configuration, all you need to do is to create files in the main project folder:
webpack.config.js for any shared configwebpack.dev.config.js for any config used by 2021ai-grace-app serve commandwebpack.prod.config.js for any config used by 2021ai-grace-app build commandThe serve command will take libraries webpack.dev.config.js, extend it with your webpack.config.js and then extend
it with your webpack.dev.config.js
The build command will take libraries webpack.prod.config.js, extend it with your webpack.config.js and then extend
it with your webpack.prod.config.js
This node package provides cli commands to enable Grace users to build their React apps. We wrap the provided app in our
code as defined in src/index.js. The wrapping script can be found under scripts/wrap.js.
To start working with this project:
yarn installyarn build and yarn npm publish. Remember to bump version in package.json.In development, you can use local node registry like Verdaccio to publish this package. If you do, point to your local registry in .yarnrc.yml in workspace main path.
You can use my-app in this workspace (in the parent folder) to test grace-app as a dependency.
Download counts and popularity will appear here as the collector receives them.
| Package / target | Requirement | Relationship |
|---|---|---|
yargsEnvironment{
"local_name": "yargs",
"alias": false,
"peer_metadata": null
} | ^17.7.2 | runtime |
@babel/coreEnvironment{
"local_name": "@babel/core",
"alias": false,
"peer_metadata": null
} | 7.13.15 | development |
@babel/plugin-transform-runtimeEnvironment{
"local_name": "@babel/plugin-transform-runtime",
"alias": false,
"peer_metadata": null
} | ^7.13.15 | development |
@babel/preset-envEnvironment{
"local_name": "@babel/preset-env",
"alias": false,
"peer_metadata": null
} | ^7.13.15 | development |
@babel/preset-reactEnvironment{
"local_name": "@babel/preset-react",
"alias": false,
"peer_metadata": null
} | 7.13.13 | development |
@babel/runtimeEnvironment{
"local_name": "@babel/runtime",
"alias": false,
"peer_metadata": null
} | ^7.13.10 | development |
@types/reactEnvironment{
"local_name": "@types/react",
"alias": false,
"peer_metadata": null
} | ^18.2.14 | development |
@webpack-cli/serveEnvironment{
"local_name": "@webpack-cli/serve",
"alias": false,
"peer_metadata": null
} | ^1.3.1 | development |
axiosEnvironment{
"local_name": "axios",
"alias": false,
"peer_metadata": null
} | ^1.4.0 | development |
babel-loaderEnvironment{
"local_name": "babel-loader",
"alias": false,
"peer_metadata": null
} | 8.2.2 | development |
css-loaderEnvironment{
"local_name": "css-loader",
"alias": false,
"peer_metadata": null
} | ^5.2.1 | development |
html-webpack-pluginEnvironment{
"local_name": "html-webpack-plugin",
"alias": false,
"peer_metadata": null
} | ^5.5.3 | development |
json-loaderEnvironment{
"local_name": "json-loader",
"alias": false,
"peer_metadata": null
} | ^0.5.7 | development |
prettierEnvironment{
"local_name": "prettier",
"alias": false,
"peer_metadata": null
} | ^3.0.0 | development |
reactEnvironment{
"local_name": "react",
"alias": false,
"peer_metadata": null
} | ^18.2.0 | development |
react-domEnvironment{
"local_name": "react-dom",
"alias": false,
"peer_metadata": null
} | ^18.2.0 | development |
style-loaderEnvironment{
"local_name": "style-loader",
"alias": false,
"peer_metadata": null
} | 2.0.0 | development |
ts-loaderEnvironment{
"local_name": "ts-loader",
"alias": false,
"peer_metadata": null
} | ^9.4.4 | development |
typescriptEnvironment{
"local_name": "typescript",
"alias": false,
"peer_metadata": null
} | ^5.1.6 | development |
webpackEnvironment{
"local_name": "webpack",
"alias": false,
"peer_metadata": null
} | ^5.88.2 | development |
webpack-cliEnvironment{
"local_name": "webpack-cli",
"alias": false,
"peer_metadata": null
} | 4.10.0 | development |
webpack-dev-serverEnvironment{
"local_name": "webpack-dev-server",
"alias": false,
"peer_metadata": null
} | 4.15.1 | development |
axiosEnvironment{
"local_name": "axios",
"alias": false,
"peer_metadata": null
} | ^1.4.0 | peer |
reactEnvironment{
"local_name": "react",
"alias": false,
"peer_metadata": {
"optional": true
}
} | ^18.2.0 | peer |
Source distribution
{
"integrity": "sha512-aHZ6Amf0blCb879SWd7lX4nzNOEAYY1KQpUKKmgOq1N7Rc3dqwgjd8+TQq3SgMJpwbW2yteorhV+NqkdoOzYZA==",
"shasum": "05c0570b175a685660f9fb1554fb445d961851d9",
"tarball": "https://registry.npmjs.org/2021ai-grace-app/-/2021ai-grace-app-0.0.8.tgz",
"fileCount": 12,
"unpackedSize": 34361,
"signatures": [
{
"keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA",
"sig": "MEQCIH3cCn/vQ2B+cWDdOICbMKvcmSFftPWzjPk+TuxKMDQ9AiALfYsdPEMq/muiQmRxsx8x+HG3q9LEhAXDde/DQUamtQ=="
}
]
}Observed since 20 Oct, 18:54 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package_version:3a50b87a75f5392c64a8b5ca5f6d10bdf142bd709b0f5633ee366f280a084637