The ML family is really good at (safe!) string processing, e.g. the meme that they're only good for writing compilers.
Lots of Web stuff is just that (DB queries, GET/POST parameters, HTML, templating, URLs, JSON, XML, etc.). Whilst lots of that can be done via bytes, there are certainly cases where Unicode is needed (e.g. finding word boundaries, case-insensitive comparison, etc.).
Ocaml (and SML) have the enviable position of being safer+faster than scripting languages, and more approachable+familiar than the likes of Haskell (which otherwise has a similar feature set). That makes it very well suited to such domains IMHO.
^ This. Exactly my experience with it. Though, recently I'm using Java when I work with others on cloud-related projects and Scala (which is a ML+typeclasses+concurrency on the JVM) to write a compiler for OpenCL. For me, OCaml is great if you want compilation speed, fast iterations. Lacks in other departments: concurrency, parallelism, ergonomics, availability of libraries (outside compiler territory). Also, there's Flix that can have a lot of potential in the future, which is on JVM also: https://flix.dev/
Even if you need, for example, word boundaries, you might be better off pretending that no non-ASCII non-word chars exist than pretending that everything is valid UTF-8 or whatever. Depends on your inputs and requirements.
Lots of Web stuff is just that (DB queries, GET/POST parameters, HTML, templating, URLs, JSON, XML, etc.). Whilst lots of that can be done via bytes, there are certainly cases where Unicode is needed (e.g. finding word boundaries, case-insensitive comparison, etc.).
Ocaml (and SML) have the enviable position of being safer+faster than scripting languages, and more approachable+familiar than the likes of Haskell (which otherwise has a similar feature set). That makes it very well suited to such domains IMHO.