tim-kos / node-retry

Abstraction for exponential and custom retry strategies for failed operations.
Other
1.22k stars 80 forks source link

commonjs -> ecmascript modules #87

Open brandonros opened 2 years ago

brandonros commented 2 years ago

not sure what to do about the tests (ending in .js and doing require()) as well as package.json engines talking about node >= version 4

brandonros commented 2 years ago
<script type="importmap">
      {
        "imports": {
          "retry": "https://cdn.jsdelivr.net/gh/brandonros/node-retry@mjs/index.mjs",
          "p-retry": "https://cdn.jsdelivr.net/npm/p-retry@5.1.1/index.js"
        }
      }
    </script>
    <script type="module">
      import retry from 'retry'
      import pRetry from 'p-retry'

     ...

opens the door for this without the use of a bundler