Objective
This recipe demonstrates how to use built-in Dojo ponyfills within your app. This recipe will focus on the Array.from
ponyfill.
Procedure
- Import the
Array.from
function:
import { from } from '@dojo/shim/array';
- Use the imported function:
from('hello'); // ["h", "e", "l", "l", "o"]
Additional resources
- Explanation on what a ponyfill is
- Dojo Shim GitHub project