5 ms·
This would better be solved with keywords / literal types / singelton types ['Ford', 'BWM', 'Volvo'].sort(`reverse) TypeScript can do that with strings: htt
by tomp 6y ago
This would better be solved with keywords / literal types / singelton types
['Ford', 'BWM', 'Volvo'].sort(`reverse)
TypeScript can do that with strings: https://www.typescriptlang.org/docs/handbook/literal-types.html https://www.typescriptlang.org/docs/handbook/literal-types.h...