Yuki Takei 6 лет назад
Родитель
Сommit
5ac04219a9

+ 3 - 0
packages/growi-plugin-attachment-refs/.eslintignore

@@ -0,0 +1,3 @@
+/.github/**
+/.vscode/**
+/node_modules/**

+ 31 - 0
packages/growi-plugin-attachment-refs/.eslintrc.js

@@ -0,0 +1,31 @@
+module.exports = {
+  extends: [
+    'weseek',
+    'weseek/react',
+  ],
+  env: {
+  },
+  globals: {
+  },
+  plugins: [
+  ],
+  rules: {
+    'indent': [
+      'error',
+      2,
+      {
+        SwitchCase: 1,
+        ignoredNodes: ['JSXElement *', 'JSXElement', 'JSXAttribute', 'JSXSpreadAttribute'],
+        ArrayExpression: 'first',
+        FunctionDeclaration: { body: 1, parameters: 2 },
+        FunctionExpression: { body: 1, parameters: 2 },
+      },
+    ],
+    'react/jsx-filename-extension': [
+      'warn',
+      { extensions: ['.jsx']},
+    ],
+    // eslint-plugin-import rules
+    'import/no-unresolved': [2, { ignore: ['^@'] }], // ignore @alias/..., @commons/..., ...
+  },
+};

+ 1 - 0
packages/growi-plugin-attachment-refs/index.js

@@ -0,0 +1 @@
+module.exports = require('./src/meta');

+ 14 - 4
packages/growi-plugin-attachment-refs/package.json

@@ -11,6 +11,11 @@
     "src"
   ],
   "scripts": {
+    "lint:js:fix": "eslint **/*.{js,jsx} --fix",
+    "lint:js": "eslint **/*.{js,jsx}",
+    "lint:styles:fix": "prettier-stylelint --quiet --write src/**/*.scss",
+    "lint:styles": "stylelint src/**/*.scss",
+    "lint": "npm-run-all -p lint:js lint:styles",
     "test": ""
   },
   "repository": "https://github.com/weseek/growi-plugin-attachment-refs",
@@ -20,15 +25,20 @@
     "url": "https://github.com/weseek/growi-plugin-attachment-refs/issues"
   },
   "dependencies": {
-    "growi-pluginkit": "^1.1.0"
+    "growi-commons": "^4.0.1"
   },
   "devDependencies": {
+    "babel-eslint": "^10.0.2",
     "babel-preset-env": "^1.7.0",
     "babel-preset-react": "^6.24.1",
-    "eslint": "^5.15.0",
+    "eslint": "^5.15.1",
+    "eslint-config-weseek": "^1.0.1",
+    "eslint-plugin-import": "^2.16.0",
     "eslint-plugin-react": "^7.12.4",
-    "react": "^16.8.3",
-    "react-dom": "^16.8.3"
+    "npm-run-all": "^4.1.5",
+    "prettier-stylelint": "^0.4.2",
+    "react": "^16.4.1",
+    "react-dom": "^16.4.1"
   },
   "engines": {
     "node": ">=8.11.1 <11",

+ 2 - 0
packages/growi-plugin-attachment-refs/src/client-entry.js

@@ -0,0 +1,2 @@
+export default (appContainer) => {
+};

+ 0 - 0
packages/growi-plugin-attachment-refs/src/client/js/util/preprocessor/attachment-refs.js


+ 11 - 0
packages/growi-plugin-attachment-refs/src/meta.js

@@ -0,0 +1,11 @@
+const path = require('path');
+
+module.exports = {
+  pluginSchemaVersion: 3,
+  serverEntries: [
+    path.join(__dirname, 'server-entry.js'),
+  ],
+  clientEntries: [
+    path.join(__dirname, 'client-entry.js'),
+  ],
+};

+ 2 - 0
packages/growi-plugin-attachment-refs/src/server-entry.js

@@ -0,0 +1,2 @@
+module.exports = (crowi, app) => {
+};

Разница между файлами не показана из-за своего большого размера
+ 747 - 21
packages/growi-plugin-attachment-refs/yarn.lock


Некоторые файлы не были показаны из-за большого количества измененных файлов