summaryrefslogtreecommitdiff
path: root/runtime/js/40_plugins.js
blob: 0796fd5cee4a9cd2d1f12df3348f24d14b9b11f0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// Copyright 2018-2021 the Deno authors. All rights reserved. MIT license.
"use strict";

((window) => {
  const core = window.Deno.core;

  function openPlugin(filename) {
    const rid = core.opSync("op_open_plugin", filename);
    core.syncOpsCache();
    return rid;
  }

  window.__bootstrap.plugins = {
    openPlugin,
  };
})(this);