File tree Expand file tree Collapse file tree
packages/@glimmer/runtime/lib/helpers Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import { DEBUG } from '@glimmer/env' ;
22
3- export const eq = ( ...args : unknown [ ] ) => {
4- if ( DEBUG && args . length !== 2 ) {
5- throw new Error ( `\`eq\` expects exactly two arguments, but received ${ args . length } .` ) ;
3+ /**
4+ * Performs a strict equality comparison.
5+ *
6+ * left === right
7+ */
8+ export function eq ( left : unknown , right : unknown ) {
9+ if ( DEBUG && arguments . length !== 2 ) {
10+ throw new Error ( `\`eq\` expects exactly two arguments, but received ${ arguments . length } .` ) ;
611 }
712
8- return args [ 0 ] === args [ 1 ] ;
9- } ;
13+ return left === right ;
14+ }
Original file line number Diff line number Diff line change 11import { DEBUG } from '@glimmer/env' ;
22
3- export const neq = ( ...args : unknown [ ] ) => {
4- if ( DEBUG && args . length !== 2 ) {
5- throw new Error ( `\`neq\` expects exactly two arguments, but received ${ args . length } .` ) ;
3+ /**
4+ * Performs a strict inequality comparison.
5+ *
6+ * left !== right
7+ */
8+ export function neq ( left : unknown , right : unknown ) {
9+ if ( DEBUG && arguments . length !== 2 ) {
10+ throw new Error ( `\`neq\` expects exactly two arguments, but received ${ arguments . length } .` ) ;
611 }
712
8- return args [ 0 ] !== args [ 1 ] ;
9- } ;
13+ return left !== right ;
14+ }
You can’t perform that action at this time.
0 commit comments