Skip to content

Commit a1a4a82

Browse files
committed
chore: upgrade to v3.2.0
1 parent 0d52865 commit a1a4a82

15 files changed

Lines changed: 1870 additions & 17707 deletions

.github/workflows/ci.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Continuous Integration
2+
3+
on: [push, pull_request]
4+
5+
permissions:
6+
contents: read
7+
8+
jobs:
9+
continuous-integration:
10+
runs-on: ubuntu-latest
11+
timeout-minutes: 10
12+
steps:
13+
- uses: actions/checkout@v7
14+
15+
- uses: actions/setup-node@v7
16+
with:
17+
node-version-file: .nvmrc
18+
cache: npm
19+
20+
- name: Install dependencies
21+
run: npm ci
22+
23+
- name: Run tests
24+
run: npm test
25+
26+
- name: Build
27+
run: npm run build

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
# production
1212
/build
13+
/dist
1314

1415
# misc
1516
.DS_Store

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
24

README.md

Lines changed: 13 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,21 @@
11
# featurevisor-example-react
22

3-
This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app) showing how to use [Featurevisor](https://featurevisor.com/) SDK.
3+
Example of using the [Featurevisor React SDK](https://featurevisor.com/docs/react/) in a React application built with Vite.
44

5-
## Links
5+
The application creates a Featurevisor instance, supplies it through `FeaturevisorProvider`, and evaluates the `baz` feature with `useFlag`.
66

7-
- Website: https://featurevisor.com/
8-
- SDK docs: https://featurevisor.com/docs/sdks/
9-
- React integration: https://featurevisor.com/docs/react/
7+
## Setup
108

11-
## Available Scripts
9+
```sh
10+
npm ci
11+
```
1212

13-
In the project directory, you can run:
13+
## Usage
1414

15-
### `npm start`
16-
17-
Runs the app in the development mode.\
18-
Open [http://localhost:3000](http://localhost:3000) to view it in your browser.
19-
20-
The page will reload when you make changes.\
21-
You may also see any lint errors in the console.
22-
23-
### `npm test`
24-
25-
Launches the test runner in the interactive watch mode.\
26-
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
27-
28-
### `npm run build`
29-
30-
Builds the app for production to the `build` folder.\
31-
It correctly bundles React in production mode and optimizes the build for the best performance.
32-
33-
The build is minified and the filenames include the hashes.\
34-
Your app is ready to be deployed!
35-
36-
See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
37-
38-
### `npm run eject`
39-
40-
**Note: this is a one-way operation. Once you `eject`, you can't go back!**
41-
42-
If you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
43-
44-
Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own.
45-
46-
You don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it.
47-
48-
## Learn More
49-
50-
You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
51-
52-
To learn React, check out the [React documentation](https://reactjs.org/).
53-
54-
To learn Featurevisor, checkout the [Featurevisor documentation](https://featurevisor.com).
15+
```sh
16+
npm run dev
17+
npm test
18+
npm run build
19+
```
5520

21+
Visit [featurevisor.com](https://featurevisor.com) for the complete documentation.

index.html

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
6+
<meta
7+
name="description"
8+
content="Featurevisor React SDK integration example"
9+
/>
10+
<title>Featurevisor with React</title>
11+
</head>
12+
<body>
13+
<noscript>You need to enable JavaScript to run this application.</noscript>
14+
<div id="root"></div>
15+
<script type="module" src="/src/main.jsx"></script>
16+
</body>
17+
</html>

0 commit comments

Comments
 (0)