remove method

String remove(
  1. String substring
)

Removes all occurrences of the specified substring.

Example:

'hello world'.remove('l'); // 'heo word'

Implementation

String remove(String substring) => replaceAll(substring, '');