freemail is a Node.js module that provides a programmatic interface to identify whether an email domain is considered 'free' (e.g., gmail.com) or 'disposable' (e.g., mailinater.com). It ships with a database of domains categorized into `free.txt`, `disposable.txt`, and `blacklist.txt`. The package is currently at version 1.7.0. Its primary differentiator is the included, updateable domain database, which can be synchronized from various online sources. However, the project appears to be unmaintained, with its last update several years ago, meaning the included data may be significantly out of date unless manually refreshed by the user. There is no clear release cadence, and new development has ceased.
npm install freemailVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to use `freemail` to check if various email addresses belong to free or disposable email providers, illustrating its core functionality.
For ES Module projects, you must use `require()` through a compatibility layer or configure your build system (e.g., Webpack, Rollup) to handle CommonJS modules. The simplest approach for a pure Node.js ESM project is often to create a wrapper file that uses `require()` and then re-exports.
Users must manually update the database by running the `./update` script provided within the package's `node_modules/freemail` directory. Be aware that this script itself may have outdated dependencies or fail due to changes in external data sources. For critical applications, consider alternatives or manually curating your own domain lists.
Periodically inspect the `sources.txt` file and the `./update` script for potential issues. If the script fails, manual intervention may be required to fix the script or update the `sources.txt` to point to valid and current data providers.
For comprehensive coverage, users should augment the `freemail` database with their own lists or contribute updates to the project's GitHub repository, although contributions may not be merged due to project abandonment.
Use `const freemail = require('freemail');` instead. If in a pure ESM file, consider a wrapper function or a dynamic import (e.g., `const freemail = await import('freemail');` if the package supports it, which this one likely doesn't without CJS interop).Ensure `const freemail = require('freemail');` is used at the top level of a CommonJS file. Verify the package is correctly installed and accessible.Manually inspect `node_modules/freemail/sources.txt` and the `node_modules/freemail/update` script. Update URLs, adapt parsing logic, or replace problematic sources to ensure successful data synchronization.
No dependency data recorded yet.