Closed Ahmed3rab closed 3 years ago
Convert your single quotes to double quotes, and it should validate. Parse your JSON through a validator, such as https://jsonlint.com/, to check for any errors.
Technically TinyMCE is expecting a JavaScript object, not strictly JSON, where single quotes are valid, however we can't validate that within the default configuration with Statamic - but we can validate JSON. So either using double quotes (which is valid JSON), or I'd need to disable validation - and I feel that keeping it as JSON validation has value given how complicated configuration settings can become.
Sorry for the late reply. Everything went great after converting the single quotes to double! Thanks
I've just released v1.0.1 which has an updated readme note about validating the configuration as JSON.
Outside of Statamic, you can use a typical JavaScript object - but I felt validation had potential to be useful. But at the same time, you have raised a valid point, so am happy to also remove the in-Statamic validation if it makes on-boarding easier too.
Although I use the same config object in a codepen, it always triggers a validation error Here's the object![Imgur](https://i.imgur.com/qbwEcGQ.png)