Przeglądaj źródła

Feature: README and installation guide completed.

lfabl 1 tydzień temu
rodzic
commit
7ddf4ee4bd
3 zmienionych plików z 61 dodań i 14 usunięć
  1. 20 6
      README.md
  2. 37 4
      example/src/pages/implementation/index.tsx
  3. 4 4
      package.json

+ 20 - 6
README.md

@@ -5,16 +5,30 @@ The NCore, NİBGAT® UI - Kit. The NİBGAT®'s UI / Component Library.
 
 NCore UI Kit provides built-in configuration tools to maintain standard coding guidelines and ensure seamless integration across NİBGAT projects.
 
-### 1. Environment Setup (One-Click)
+### 1. Type & Lint Configuration (Optional)
 
-If you want to use the exact same ESLint rules, TypeScript configs, and VSCode settings used in NCore UI Kit, simply run the setup command in your project root:
+If you want to use the exact same ESLint rules, TypeScript configs, and VSCode settings used in NCore UI Kit, run the type-kit command in your project root:
+
+```bash
+npx ncore-type-kit
+```
+*This command safely merges `.vscode/`, `eslint.config.mjs`, `eslint-local-rules/`, and `tsconfig.json` (preserves your existing include/exclude options) to your project.*
+
+### 2. Auto Configuration for Webpack & Metro
+
+To automatically inject NCore UI Kit plugins into your existing `webpack.config.js` and `metro.config.js`, you can run:
 
 ```bash
 npx ncore-setup
 ```
-*This command automatically copies `.vscode/`, `eslint.config.mjs`, `eslint-local-rules/`, and `tsconfig.json` to your project.*
 
-### 2. Webpack Configuration (React Native Web)
+If you only want to configure one specific platform, use:
+```bash
+npx ncore-setup-web     # Only updates webpack.config.js
+npx ncore-setup-mobile  # Only updates metro.config.js
+```
+
+### 3. Manual Webpack Configuration (React Native Web)
 
 When building a web project with React Native Web, you have two options:
 
@@ -54,9 +68,9 @@ let config = {
 module.exports = withNCoreUIKitWebpack(config, webpack);
 ```
 
-### 3. Metro Configuration (React Native Mobile)
+### 4. Manual Metro Configuration (React Native Mobile)
 
-If you are using this library in a React Native or Expo mobile project, you must update your `metro.config.js` to include the required Node.js core module polyfills (`crypto`, `process`, `stream`).
+If you did not use `npx ncore-setup` and are using this library in a React Native or Expo mobile project, you must manually update your `metro.config.js` to include the required Node.js core module polyfills (`crypto`, `process`, `stream`).
 
 **For Expo Projects:**
 

+ 37 - 4
example/src/pages/implementation/index.tsx

@@ -118,7 +118,10 @@ let config = {
 
 module.exports = withNCoreUIKitWebpack(config, webpack);`;
 
-    const envSetupCode = `npx ncore-setup`;
+    const envSetupCode = `npx ncore-type-kit`;
+    const autoSetupCode = `npx ncore-setup
+# Sadece web için: npx ncore-setup-web
+# Sadece mobil için: npx ncore-setup-mobile`;
 
     return <PageContainer
         isWorkWithHeaderSpace={false}
@@ -169,7 +172,37 @@ module.exports = withNCoreUIKitWebpack(config, webpack);`;
                 variant="bodyMediumSize"
                 color="mid"
             >
-                Mobil (React Native / Expo) ortamında kurulum yaparken, Node.js core modül polyfill'leri (crypto, process, stream) için metro.config.js dosyanızı NCore UIKit ile sarmalamanız (wrap) gerekir.
+                Web (Webpack) ve Mobil (Metro) ayarlarınızı NCore UI Kit ile uyumlu hale getirmek için otomatik kurulum komutlarını kullanabilirsiniz:
+            </Text>
+            <View
+                style={[
+                    stylesheet.borderedCard,
+                    {
+                        backgroundColor: colors.content.container.default,
+                        borderColor: colors.content.border.subtle,
+                        marginBottom: spaces.spacingMd,
+                        padding: spaces.spacingMd
+                    }
+                ]}
+            >
+                <Text
+                    variant="headlineSmallSize"
+                >
+                    Terminal (Otomatik Yapılandırma)
+                </Text>
+                <CodeViewer
+                    code={autoSetupCode}
+                    language="bash"
+                />
+            </View>
+            <Text
+                style={{
+                    marginBottom: spaces.spacingMd
+                }}
+                variant="bodyMediumSize"
+                color="mid"
+            >
+                Mobil (React Native / Expo) ortamında kurulum yaparken, otomatik kurulumu tercih etmezseniz metro.config.js dosyanızı NCore UIKit ile manuel sarmalamanız (wrap) gerekir.
             </Text>
             <View
                 style={[
@@ -220,7 +253,7 @@ module.exports = withNCoreUIKitWebpack(config, webpack);`;
                 variant="bodyMediumSize"
                 color="mid"
             >
-                Web (React Native Web) ortamında derleme yapmak için NCore'un hazır Webpack ayarını kullanabilir veya mevcut ayarınızı sarmalayabilirsiniz.
+                Web (React Native Web) ortamında derleme yapmak için, otomatik kurulumu kullanmak yerine NCore'un hazır Webpack ayarını kullanabilir veya mevcut ayarınızı manuel sarmalayabilirsiniz.
             </Text>
             <View
                 style={[
@@ -287,7 +320,7 @@ module.exports = withNCoreUIKitWebpack(config, webpack);`;
                 <Text
                     variant="headlineSmallSize"
                 >
-                    Terminal
+                    Terminal (Tip ve Lint Ayarları)
                 </Text>
                 <CodeViewer
                     code={envSetupCode}

+ 4 - 4
package.json

@@ -76,14 +76,14 @@
     ],
     "repository": {
         "type": "git",
-        "url": "git+https://git.nibgat.space/nibgat-community/ncore-ui-kit.git.git"
+        "url": "git+https://git.nibgat.space/nibgat/ncore-ui-kit.git.git"
     },
-    "author": "nibgat <development@nibgat.com> (https://git.nibgat.space/nibgat-community)",
+    "author": "nibgat <development@nibgat.com> (https://git.nibgat.space/nibgat)",
     "license": "MIT",
     "bugs": {
-        "url": "https://git.nibgat.space/nibgat-community/ncore-ui-kit.git/issues"
+        "url": "https://git.nibgat.space/nibgat/ncore-ui-kit.git/issues"
     },
-    "homepage": "https://git.nibgat.space/nibgat-community/ncore-ui-kit.git#readme",
+    "homepage": "https://git.nibgat.space/nibgat/ncore-ui-kit.git#readme",
     "publishConfig": {
         "registry": "https://registry.npmjs.org/"
     },