grapesjs-plugin-s3
v0.1.8
Published
Enable s3 uploader inside the Asset Manager
Downloads
36
Maintainers
Readme
GrapesJS S3
This plugin replaces the default file uploader with the one from Filestack
Summary
- Plugin
- Name:
gjs-plugin-s3
- Options:
- imgFormats: ["png", "jpeg", "jpg"],
- bucketName: "bodylesscms",
- prefix: "content/img/",
- accessKeyId:
<AWS Access key Id>
, - secretAccessKey:
<Aws secret access key>
, - sessionToken:
<AWS Sessions Token>
- Name:
Download
npm i grapesjs-plugin-s3
Usage
<link href="path/to/grapes.min.css" rel="stylesheet"/>
<link href="path/to/grapesjs-plugin-s3.css" rel="stylesheet"/>
<script src="path/to/grapes.min.js"></script>
<script src="path/to/grapesjs-plugin-s3.min.js"></script>
<div id="gjs"></div>
<script type="text/javascript">
var editor = grapesjs.init({
container : '#gjs',
plugins: ['gjs-plugin-s3'],
pluginsOpts: {
'gjs-plugin-s3': {/* ...options */}
}
});
</script>
Development
Clone the repository
$ git clone https://github.com/chaitanya11/grapesjs-plugin-s3.git
$ cd grapesjs-plugin-s3
Install it
$ npm i
The plugin relies on GrapesJS via peerDependencies
so you have to install it manually (without adding it to package.json)
$ npm i grapesjs --no-save
Start the dev server
$ npm start
License
BSD 3-Clause