From f22ba992143158e01be0413aa3ba04d0d5c3a8e8 Mon Sep 17 00:00:00 2001 From: Franz Liedke Date: Fri, 24 Jan 2020 17:42:14 +0100 Subject: [PATCH] Clarify the use-case of the JS slug helper --- framework/core/js/src/common/utils/string.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/framework/core/js/src/common/utils/string.js b/framework/core/js/src/common/utils/string.js index 291e7bc7f..bab89c5e2 100644 --- a/framework/core/js/src/common/utils/string.js +++ b/framework/core/js/src/common/utils/string.js @@ -16,6 +16,10 @@ export function truncate(string, length, start = 0) { * Create a slug out of the given string. Non-alphanumeric characters are * converted to hyphens. * + * NOTE: This method does not use the comparably sophisticated transliteration + * mechanism that is employed in the backend. Therefore, it should only be used + * to *suggest* slugs that can be overridden by the user. + * * @param {String} string * @return {String} */