0.0.1 • Published 1 year ago

sqlite3-embedded-loader v0.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

SQLite3 Embedded Loader

This plugin allows you to bundle an entire server powered by Express/Fastify + NestJS + typeorm/knex or others into a single JavaScript executable, eliminating the need for a node_modules folder.

Features

  • Bundles sqlite3 into an additional .node file in your dist folder.
  • Uses node-loader to load the sqlite3.node file.

Supported Versions

  • SQLite3: 5.1.7
  • SQLite3 Embedded Loader: 1.0.0

Please note that this is an alternative to the sqlite3-loader package, which allowed bundling sqlite3 with webpack on sqlite3 versions <= 5.1.6. Unfortunately, cross-compilation is not supported by the bindings of node-sqlite3.

//webpack.config.js
      module: {
        rules: [
          {
            test: /.node$/,
            loader: 'node-loader',
            options: {
              name: '[name].[ext]',
            },
          },
          {
            test: /sqlite3-binding\.js$/,
            loader: 'sqlite3-embedded-loader',
          },
          {
            test: /\.(js|mjs|jsx|ts|tsx)$/,
            use: [
              {
                loader: 'babel-loader',
              },
            ],
          }
        ]
      }
0.0.1

1 year ago

0.0.10

1 year ago

0.0.9

1 year ago