Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No errors reported for missing XML entities with periods #244

Open
retorquere opened this issue Aug 19, 2018 · 1 comment
Open

No errors reported for missing XML entities with periods #244

retorquere opened this issue Aug 19, 2018 · 1 comment

Comments

@retorquere
Copy link

The following logs an error for entitymissing but not for better-bibtex.Preferences.prefpane.better-bibtex:

const parser = new xmldom.DOMParser({
  locator: {},
  errorHandler: {
    warning: function(err) { console.log('warning:', err) },
    error: function(err) { console.log('error:', err) },
    fatalError: function(err) { console.log('fatal error:', err) },
  },
})

prefsPane = `
<?xml version="1.0"?>
<overlay id="zotero-better-bibtex-preferences">
  <prefwindow id="zotero-prefs">
    <prefpane id="zotero-prefpane-better-bibtex"
            insertafter="zotero-prefpane-advanced"
            label="&better-bibtex.Preferences.prefpane.better-bibtex;"
            xlabel="&entitymissing;"
            image="chrome://zotero-better-bibtex/skin/bibtex.svg"
            onpaneload="Zotero.BetterBibTeX.Preferences.load()"
            helpTopic="BetterBibTeX"
            >
    </prefpane>
  </prefwindow>

  <script src="chrome://zotero/content/include.js"/>
  <script src="chrome://zotero-better-bibtex/content/BetterBibTeX.Preferences.js"/>
</overlay>
`
const pane = parser.parseFromString(prefsPane, 'text/xml')
@amitguptagwl
Copy link

This project is not active anymore. You can try fast-xml-parser instead

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants