1.0.1 • Published 8 months ago

simple-global-search v1.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
8 months ago

Strapi plugin global search

npm.io

Working on Strapi version: v4.0.3

First Setup

  1. Clone the plugin into your Strapi project
cd /<path-to-your-strapi-project>/src

# create plugins folder if not exists
# mkdir plugins

# go to plugins folder
cd plugins

# clone the plugin code into a folder and skip the prefix
git clone git@github.com:lazurey/strapi-plugin-content-export-import.git content-export-import
# install dependencies
cd simple-global-search && yarn install
  1. Enable the plugin in <root>/config/plugins.js .
module.exports = {
  // ...
  "simple-global-search": {
    enabled: true,
    resolve: "./src/plugins/simple-global-search",
  },
  // ...
};
  1. Build the plugin
# back to project root and build the plugin
yarn build
# start
yarn develop

Note:

it's important to clone the repo into a target folder named content-export-import, the prefix has to be omitted.

Plugin development

yarn develop --watch-admin

Running at http://localhost:8080/

Include the following lines to allows large excel imports in middelware.js

module.exports = [
  'strapi::errors',
  'strapi::security',
  'strapi::cors',
  'strapi::poweredBy',
  'strapi::logger',
  'strapi::query',
  {
    name: "strapi::body",
    config: {
      formLimit: "256mb", // modify form body
      jsonLimit: "256mb", // modify JSON body
      textLimit: "256mb", // modify text body
      formidable: {
        maxFileSize: 200 * 1024 * 1024, // multipart data, modify here limit of uploaded file size
      },
    },
  },
  //'strapi::body',
  'strapi::session',
  'strapi::favicon',
  'strapi::public',
];

Features

  • Support JSON export & import
  • Delete all content of a type

Not supported

  • Media fields, e.g. image, video, etc.
  • Any other file type, e.g. csv, etc.

References