allow 'cast' for the JS target