项目作者: nodef

项目描述 :
E numbers are codes for substances that are permitted to be used as food additives for use within the European Union and EFTA.
高级语言: JavaScript
项目地址: git://github.com/nodef/food-e.git
创建时间: 2020-02-09T22:06:14Z
项目社区:https://github.com/nodef/food-e

开源协议:MIT License

下载


This is a package that allows you to programmatically access E number and INS number data for food additives, including their names, types, and (approval) status.


📦 @nodef/food-additive">JSR,
📰 @nodef/food-additive/doc">Docs.




Reference

Method Action
@nodef/food-additive/doc/~/e">e Find matching food additives with a code/names/type/status query (E number).
@nodef/food-additive/doc/~/ins">ins Find matching food additives with a code/names/type/status query (INS number).




E numbers

E numbers are codes for substances that are permitted to be used as food additives for use within the European Union and EFTA. Commonly found on food labels, their safety assessment and approval are the responsibility of the European Food Safety Authority.

Having a single unified list for food additives was first agreed upon in 1962 with food colouring. In 1964, the directives for preservatives were added, 1970 for antioxidants and 1974 for the emulsifiers, stabilisers, thickeners and gelling agents.


  1. import * as foodAdditive from "jsr:@nodef/food-additive";
  2. // foodAdditive.loadE() → corpus
  3. // foodAdditive.eSql([table], [options]) → SQL statements
  4. // foodAdditive.eCsv() → Path of CSV file
  5. // foodAdditive.e(query)
  6. // → matching [{code, names, type, status}]
  7. await foodAdditive.loadE();
  8. // Load corpus first
  9. foodAdditive.e('E101a');
  10. // → [ { code: 'E101a',
  11. // → names: 'Riboflavin-5\'-Phosphate',
  12. // → type: 'color (Yellow-orange)',
  13. // → status: 'e' } ]
  14. foodAdditive.e('101 a');
  15. // → [ { code: 'E101a',
  16. // → names: 'Riboflavin-5\'-Phosphate',
  17. // → type: 'color (Yellow-orange)',
  18. // → status: 'e' } ]
  19. foodAdditive.e('riboflavin');
  20. // → [ { code: 'E101a',
  21. // → names: 'Riboflavin-5\'-Phosphate',
  22. // → type: 'color (Yellow-orange)',
  23. // → status: 'e' },
  24. // → { code: 'E106',
  25. // → names: 'Riboflavin-5-Sodium Phosphate',
  26. // → type: 'color (Yellow)',
  27. // → status: '' },
  28. // → ... ]




INS numbers

The International Numbering System for Food Additives (INS) is a European-based naming system for food additives. It is defined by Codex Alimentarius, the WHO, and the FAO.

Class Names and the International Numbering System for Food Additives, was first published in 1989, with revisions in 2008 and 2011. The INS is an open list, “subject to the inclusion of additional additives or removal of existing ones on an ongoing basis”.


  1. import * as foodAdditive from "jsr:@nodef/food-additive";
  2. await foodAdditive.loadI();
  3. // Load corpus first
  4. foodAdditive.ins('102');
  5. // → [ { code: '102',
  6. // → names: 'tartrazine',
  7. // → type: 'colour (yellow and orange) (FDA: FD&C Yellow #5)',
  8. // → status: 'a e' } ]
  9. foodAdditive.ins('ins 102');
  10. // → [ { code: '102',
  11. // → names: 'tartrazine',
  12. // → type: 'colour (yellow and orange) (FDA: FD&C Yellow #5)',
  13. // → status: 'a e' } ]
  14. foodAdditive.ins('ins 160 d (iii)');
  15. // → [ { code: '160d(iii)',
  16. // → names: 'lycopene, Blakeslea trispora',
  17. // → type: 'colour',
  18. // → status: 'a e' },
  19. // → { code: '160d', names: 'lycopenes', type: '', status: 'a e' },
  20. // → ... ]




License

As of 23 April 2025, this project is licensed under AGPL-3.0. Previous versions remain under MIT.






ORG