bibtexの文字列をObjectに変更する
const bibtexText = `@ARTICLE{10.3389/fcimb.2020.580096,
AUTHOR={Narayan, Rohan and Tripathi, Shashank},
TITLE={Intrinsic ADE: The Dark Side of Antibody Dependent Enhancement During Dengue Infection},
JOURNAL={Frontiers in Cellular and Infection Microbiology},
VOLUME={10},
YEAR={2020},
URL={https://www.frontiersin.org/articles/10.3389/fcimb.2020.580096},
DOI={10.3389/fcimb.2020.580096},
ISSN={2235-2988},
}
@article{10.1371/journal.pntd.0000890,
doi = {10.1371/journal.pntd.0000890},
author = {Beatty, Mark E. AND Stone, Amy AND Fitzsimons, David W. AND Hanna, Jeffrey N. AND Lam, Sai Kit AND Vong, Sirenda AND Guzman, Maria G. AND Mendez-Galvan, Jorge F. AND Halstead, Scott B. AND Letson, G. William AND Kuritsky, Joel AND Mahoney, Richard AND Margolis, Harold S. AND for {The Asia-Pacific and Americas Dengue Prevention Boards Surveillance Working Group}},
journal = {PLOS Neglected Tropical Diseases},
publisher = {Public Library of Science},
title = {Best Practices in Dengue Surveillance: A Report from the Asia-Pacific and Americas Dengue Prevention Boards},
year = {2010},
month = {11},
volume = {4},
url = {https://doi.org/10.1371/journal.pntd.0000890},
pages = {1-7},
number = {11},
}`;
// 何かparseする機能を実装 ここでは parseBibTex()とする
const bibtexObjects = parseBibTex(bibtexText);
console.log(bibtexObject);
/*
* 出力
*[{
* type: "article", key:"10.3389/fcimb.2020.580096",
* author: "Narayan, R., and Tripathi, S.",
* ...その他フィールドも
* },
* {
* type: "article",key:"10.1371/journal.pntd.0000890",
* author: "Beatty, M. E., Stone, A., Fitzsimons, D. W., Hanna, J. N., Lam, S. K., Vong, S., . . . for The *
* Asia-Pacific and Americas Dengue Prevention Boards Surveillance Working Group",
* ...その他フィールドも
* }]
*
*/
上みたいな感じにしたいです