![Create React App Officially Deprecated Amid React 19 Compatibility Issues](https://cdn.sanity.io/images/cgdhsj6q/production/04fa08cf844d798abc0e1a6391c129363cc7e2ab-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
XMPP identifiers (JID) for JavaScript
JID type | local | @ | domain | / | resource | usage |
---|---|---|---|---|---|---|
domain | wonderland.net | servers and components | ||||
bare | alice | @ | wonderland.net | users | ||
full | alice | @ | wonderland.net | / | rabbithole | user resource (device) |
https://en.wikipedia.org/wiki/XMPP#Decentralization_and_addressing
npm install @xmpp/jid
var JID = require('@xmpp/jid')
/*
* All return an instance of JID.JID, the new operator is optional.
*/
var addr = new JID('alice@wonderland.net/rabbithole') // OK
var addr = JID`${'alice'}@${'wonderland.net'}/${'rabbithole'}` // OK, es6 tagged template string
var addr = new JID('alice', 'wonderland.net', 'rabbithole') // BEST; see section on escaping below
addr instanceof JID.JID // true
// domain JIDs are created passing the domain as the first argument
var addr = JID('wonderland.net')
/*
* local
*/
addr.local = 'alice'
addr.local // alice
// same as
addr.setLocal('alice')
addr.getLocal() // alice
/*
* domain
*/
addr.domain = 'wonderland.net'
addr.domain // wonderland.net
// same as
addr.setDomain('wonderland.net')
addr.getDomain() // wonderland.net
/*
* resource
*/
addr.resource = 'rabbithole'
addr.resource // rabbithole
// same as
addr.setResource('rabbithole')
addr.getResource() // rabbithole
addr.toString() // alice@wonderland.net/rabbithole
addr.bare() // returns a JID without resource
addr.equals(some_jid) // returns true if the two JIDs are equal, false otherwise
// same as
JID.equal(addr, some_jid)
JID.is(addr) // returns true if the passed argument is an instance of JID.JID, false otherwise
The XEP-0106 defines a method to escape and unescape characters that aren't allowed in the local part of the JID. This library fully implement it but because @
and /
are ones of them and used as JID separators, you should always prefer the following syntax
// GOOD
new JID(local, domain, resource)
over
// BAD
new JID(local@domain/resource)
for user input.
FAQs
XMPP identifiers (JID) for JavaScript
The npm package @xmpp/jid receives a total of 13,599 weekly downloads. As such, @xmpp/jid popularity was classified as popular.
We found that @xmpp/jid demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.