Require this module as an Acorn plugin just like the following code:
import { Parser } from 'acorn';
import ImportAssertionPlugin from 'acorn-import-assertion-v2';
const MyParser = Parser.extend(ImportAssertionPlugin);
MyParser.parse(/* code */, { /* configuration*/ });
This repo is release under an MIT License