--- title: Use the React wrapper slug: latest-atomic-react-wrapper canonical_url: https://docs.coveo.com/en/atomic/latest/usage/frameworks/atomic-react-wrapper/ collection: atomic source_format: adoc --- # Use the React wrapper The integration of [JSX](https://reactjs.org/docs/introducing-jsx.html) in [React](https://reactjs.org/) projects with Atomic [web components](https://developer.mozilla.org/en-US/docs/Web/Web_Components) can be tricky. Atomic React is a wrapper around the core [Atomic](https://docs.coveo.com/en/atomic/latest/) library meant to address this issue. Since Atomic React is built on top of the core Atomic component library, most concepts that apply to the core Atomic library apply directly to Atomic React. The goal of this article is to go over the few areas where the use of Atomic React differs from the use of the core Atomic library. [TIP.successful] #### For a concrete example you may want to start from or refer to throughout this article, see this [Atomic React page](https://github.com/coveo/ui-kit/tree/master/packages/samples/atomic-react). #### == Install Atomic React ### NPM Install Atomic React using the [npm](https://www.npmjs.com/get-npm) package. ``` npm i @coveo/atomic-react ``` You can import components in your React application from the three entry points: * `@coveo/atomic-react` for the core Atomic React components. * `@coveo/atomic-react/commerce` for the commerce components. * `@coveo/atomic-react/recommendation` for the recommendation components. ```jsx import { AtomicSearchInterface } from '@coveo/atomic-react'; // import { AtomicCommerceInterface } from '@coveo/atomic-react/commerce'; // import { AtomicRecsInterface } from '@coveo/atomic-react/recommendation'; ``` ## Static assets For performance reasons, the generated Atomic React JavaScript bundle does not automatically include static assets that are loaded on demand. This impacts language support, as well as the use of included SVG icons. Make external assets distributed with Atomic React available by including them in the public directory of your app. Without this, you'll face various issues. For example, labels in the app will appear as temporary placeholders. The location of the public directory depends on how you build, configure and distribute your app. For example, for any project created with [Create React App](https://github.com/facebook/create-react-app), this would mean copying language and icon assets to the `./public` directory. ```bash cp -r node_modules/@coveo/atomic-react/dist/assets public/assets cp -r node_modules/@coveo/atomic-react/dist/lang public/lang ``` > **Note** > > Be sure to respect the folder hierarchy, with SVG icons under the `assets` subdirectory and labels and languages under the `lang` subdirectory of the public folder. ## Result templates The way to [define result templates](https://docs.coveo.com/en/atomic/latest/usage/displaying-results#defining-a-result-template) for an HTML project using the core Atomic library involves defining one or multiple [`atomic-result-template`](https://docs.coveo.com/en/atomic/latest/reference/components/atomic-result-template/) components, configured with HTML properties, adding conditions on the attributes and metadata of each result. Coupled with the [`