Skip to content

Instantly share code, notes, and snippets.

@johnfmorton
Last active August 5, 2024 09:30
Show Gist options
  • Save johnfmorton/4272cc5a8c3228816efde337cf54e06a to your computer and use it in GitHub Desktop.
Save johnfmorton/4272cc5a8c3228816efde337cf54e06a to your computer and use it in GitHub Desktop.
CKEditor config with helpful additions - custom fonts, an addition font size example, and open links in new window option
{
"alignment": {
"options": [
"left",
"center",
"right"
]
},
"code": {
"indentSequence": " "
},
"fontFamily": {
"options": [
"default",
"'system-ui', sans-serif",
"'EB Garamond', Georgia, serif"
]
},
"fontSize": {
"options": [
"tiny",
"small",
"default",
"big",
{
"model": "bigger",
"title": "Bigger",
"view": {
"classes": [
"text-bigger"
],
"name": "span"
}
},
"huge"
]
},
"link": {
"addTargetToExternalLinks": false,
"decorators": {
"openInNewTab": {
"attributes": {
"rel": "noopener noreferrer",
"target": "_blank"
},
"label": "Open in a new tab",
"mode": "manual"
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment