The jQuery Autocomplete plugin relies on an odd response format. Specifically, it's a newline-separated list of pipe-delimited pairs, the first entry of each pair being some formatted text, the latter being a JSON object with some data.
An example:
Fuzzy Bunnies|{ id: '1234-fuzzy-bunnies', type: 'slippers' }
Loud Hawaiian Shirt|{ id: '3993-loud-hawaiian-shirt', type: 'shirt', sizes: ['S', 'M', 'L'] }
My question is: what sort of MIME type makes sense for this? It's not exactly application/json
because of that odd pipe and the fact that the list is newline-delimited, not expresses as a Javascript array. Nor is it text/plain
since only the first part is plain text (and even that might allow markup -- I'm not sure).