Well, a virtual environment is just a directory with three important components:
A site-packages/ folder where third party libraries are installed.
Symlinks to Python executables installed on your system.
Scripts that ensure executed Python code uses the Python interpreter and site packages installed inside the given virtual environment.
(venv) % pip freeze
And write the output to a file, which we’ll call requirements.txt.