Comments (2)
Hi @csharpee this is duplicate of #8. As we said there, at the moment we don't have any plans to support self-hosted version in this plugin. If you want it, feel free to fork our repo and change it on your own.
Thanks
from strapi-plugin-tinymce.
@poberbeck @csharpee
For others coming here wondering how to do this the best solution at the moment might be patch-package (mentioned here https://docs.strapi.io/dev-docs/plugins-extension)
I just removed the apiKey property from the react component in this file admin/src/components/Editor/index.js and added a new one to load the JS locally...
return (
!loading && pluginConfig ?
<Editor
tinymceScriptSrc={'/tinymce/tinymce.min.js'}
value={value}
tagName={name}`
Apply the change with patch-package and then add a postinstall command to copy tinymce to your public folder...
package.json
"scripts": {
"postinstall": "node ./postinstall.js && patch-package"
},
postinstall.js
// Copy tinymce folder
const fse = require('fs-extra');
const path = require('path');
const topDir = __dirname;
fse.emptyDirSync(path.join(topDir, 'public', 'tinymce'));
fse.copySync(path.join(topDir, 'node_modules', 'tinymce'), path.join(topDir, 'public', 'tinymce'), { overwrite: true });
.gitignore
public/tinymce/*
This will remove the api key message from your tinymce editors. Would be good if the contributors would add a conditional for the tinymceScriptSrc property then it can be done natively? The above method might also be useful in the docs?
from strapi-plugin-tinymce.
Related Issues (20)
- [Video] Handle video from media library HOT 3
- strapi-plugin-tinymce and Typescript HOT 1
- Disable "Media library button" HOT 2
- After installing TinyMCE Strapi Marketplace stops working HOT 3
- Save Issue in cms due to TinyMCE. HOT 3
- Upgrade to Node 18 HOT 1
- is there a way to add media button to tinymce ui? HOT 1
- is there any way to style the table in tinymce editor ? HOT 2
- TinyMCE editor does not show up even when configured Plugin, CSP, API Key HOT 1
- How to add custom functionality? HOT 4
- Why tinymce plugin is not compatible with node v18 HOT 1
- Unauthenticated API Key Disclosure HOT 1
- to use codesample_global_prismjs: true
- Update Strapi version to support Node 20. HOT 3
- Textbox doesnot open HOT 1
- TinyMCE requires an API key HOT 1
- Save button is enabled whenever open a document in a content manager in Strapi TinyMCE HOT 1
- Tiny Editor API KEY issue - Strapi HOT 2
- Remove Media Library button if no media plugin enabled HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from strapi-plugin-tinymce.