Skip to content

Commit dc3bb39

Browse files
Merge pull request #1 from FeatureProbe/feature-init
feat: SDK 1.0.1
2 parents c2dff24 + d4510e3 commit dc3bb39

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+82270
-2
lines changed

.gitignore

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
dist/
2+
build/
3+
coverage
4+
node_modules/
5+
yarn.lock
6+
.DS_Store
7+
lib
8+
.idea
9+
.vscode/
10+
.husky/

README.md

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,35 @@
1-
# client-sdk-react
2-
FeatureProbe Client Side SDK for React
1+
# FeatureProbe Client Side SDK for React
2+
3+
[![Top Language](https://img.shields.io/github/languages/top/FeatureProbe/client-sdk-react)](https://github.com/FeatureProbe/client-sdk-react/search?l=rust)
4+
[![Coverage Status](https://coveralls.io/repos/github/FeatureProbe/client-sdk-react/badge.svg?branch=main)](https://coveralls.io/github/FeatureProbe/client-sdk-react?branch=main)
5+
[![Github Star](https://img.shields.io/github/stars/FeatureProbe/client-sdk-react)](https://github.com/FeatureProbe/client-sdk-react/stargazers)
6+
[![Apache-2.0 license](https://img.shields.io/github/license/FeatureProbe/FeatureProbe)](https://github.com/FeatureProbe/FeatureProbe/blob/main/LICENSE)
7+
8+
FeatureProbe is an open source feature management service. This SDK is used to control features in React programs. This
9+
SDK is designed primarily for use in multi-user systems such as web servers and applications.
10+
11+
## Basic Terms
12+
13+
Reading the short [Basic Terms](https://github.com/FeatureProbe/FeatureProbe/blob/main/BASIC_TERMS.md) will help to understand the code blow more easily. [中文](https://github.com/FeatureProbe/FeatureProbe/blob/main/BASIC_TERMS_CN.md)
14+
15+
## Core Data Structures
16+
17+
Reading the short [Doc](https://github.com/FeatureProbe/feature-probe-docs/blob/b8c55a35c771e4223469f1b121f8b78ab3d9bc22/docs/sdk/sdk-introduction.md?plain=1#L13-L34) about core data sturtures. [中文](https://github.com/FeatureProbe/feature-probe-docs/blob/b8c55a35c771e4223469f1b121f8b78ab3d9bc22/i18n/zh-CN/docusaurus-plugin-content-docs/current/sdk/sdk-introduction.md?plain=1#L14-L35)
18+
19+
## How to use this SDK
20+
21+
See [SDK Doc](https://docs.featureprobe.io/how-to/Client-Side%20SDKs/react-sdk/) for detail([中文](https://docs.featureprobe.io/zh-CN/how-to/Client-Side%20SDKs/react-sdk/)). For more information about SDK API, please reference [SDK API](https://featureprobe.github.io/client-sdk-react/).
22+
23+
24+
## Contributing
25+
26+
We are working on continue evolving FeatureProbe core, making it flexible and easier to use.
27+
Development of FeatureProbe happens in the open on GitHub, and we are grateful to the
28+
community for contributing bugfixes and improvements.
29+
30+
Please read [CONTRIBUTING](https://github.com/FeatureProbe/featureprobe/blob/master/CONTRIBUTING.md)
31+
for details on our code of conduct, and the process for taking part in improving FeatureProbe.
32+
33+
## License
34+
35+
This project is licensed under the Apache 2.0 License - see the [LICENSE](LICENSE) file for details.

commitlint.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
module.exports = {extends: ['@commitlint/config-conventional']}

config/tsconfig.cjs.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"extends": "../tsconfig",
3+
"compilerOptions": {
4+
"module": "commonjs",
5+
"outDir": "../dist/cjs"
6+
}
7+
}

config/tsconfig.esm.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"extends": "../tsconfig",
3+
"compilerOptions": {
4+
"module": "ESNext",
5+
"outDir": "../dist/esm"
6+
}
7+
}

config/tsconfig.types.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extends": "../tsconfig",
3+
"compilerOptions": {
4+
"declaration": true,
5+
"emitDeclarationOnly": true,
6+
"outDir": "../dist/types"
7+
}
8+
}

config/tsconfig.umd.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"extends": "../tsconfig",
3+
"compilerOptions": {
4+
"module": "commonjs",
5+
"declaration": false
6+
}
7+
}

config/webpack.config.js

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
const path = require('path')
2+
3+
module.exports = {
4+
mode: 'production',
5+
entry: './src/index.ts',
6+
output: {
7+
path: path.resolve(__dirname, '../dist/umd'),
8+
filename: 'index.js',
9+
library: 'exampleTypescriptPackage',
10+
libraryTarget: 'umd',
11+
globalObject: 'this',
12+
},
13+
module: {
14+
rules: [
15+
{
16+
test: /\.ts(x*)?$/,
17+
exclude: /node_modules/,
18+
use: {
19+
loader: 'ts-loader',
20+
options: {
21+
configFile: 'config/tsconfig.umd.json',
22+
},
23+
},
24+
},
25+
],
26+
},
27+
resolve: {
28+
extensions: ['.ts', '.js'],
29+
},
30+
}

docs/.nojekyll

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false.

docs/assets/highlight.css

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
:root {
2+
--light-code-background: #FFFFFF;
3+
--dark-code-background: #1E1E1E;
4+
}
5+
6+
@media (prefers-color-scheme: light) { :root {
7+
--code-background: var(--light-code-background);
8+
} }
9+
10+
@media (prefers-color-scheme: dark) { :root {
11+
--code-background: var(--dark-code-background);
12+
} }
13+
14+
:root[data-theme='light'] {
15+
--code-background: var(--light-code-background);
16+
}
17+
18+
:root[data-theme='dark'] {
19+
--code-background: var(--dark-code-background);
20+
}
21+
22+
pre, code { background: var(--code-background); }

0 commit comments

Comments
 (0)