def METHOD_NAME(self, name):
    """Remove a package/extension.
    name: string
        The npm package name
    """
    data = self._data
    maps = (
        data["dependencies"],
        data["resolutions"],
        data["jupyterlab"]["extensions"],
        data["jupyterlab"]["mimeExtensions"],
    )
    for m in maps:
        try:
            del m[name]
        except KeyError:
            pass
    data["jupyterlab"]["singletonPackages"].METHOD_NAME(name)