Files
notifications-admin/app/main
Chris Hill-Scott 48577b823e Add an endpoint to count the length of templates
Users sending text messages are sometimes unaware that long messages
will cost more.

Users sending broadcast messages need to be aware that there’s a
character limit, so they can take this into account when planning their
messages.

This commit adds an endpoint which counts the number of characters in
some template content, and returns a snippet of useful info about how
long the message is.

In subsequent commits we’ll be able to use AJAX to fetch this snippet as
the user types.

There’s a surprising amount of complexity in counting the length of
messages. So we’ll need to do this in Python because it would be too
convoluted to re-implement the length counting in client side code, let
alone ensuring it had parity with its Python equivalent.
2021-01-07 17:07:51 +00:00
..
2020-10-16 10:14:23 +01:00