We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 863a24a commit f8ff413Copy full SHA for f8ff413
src/version.spec.ts
@@ -0,0 +1,13 @@
1
+import { LIB_VERSION } from './version';
2
+
3
+describe('Version Module', () => {
4
+ it('should export a LIB_VERSION constant', () => {
5
+ expect(LIB_VERSION).toBeDefined();
6
+ });
7
8
+ it('should match the version specified in package.json', () => {
9
+ // eslint-disable-next-line @typescript-eslint/no-var-requires
10
+ const packageJson = require('../package.json');
11
+ expect(LIB_VERSION).toBe(packageJson.version);
12
13
+});
src/version.ts
@@ -1 +1,3 @@
-export const LIB_VERSION = '3.0.0';
+// eslint-disable-next-line @typescript-eslint/no-var-requires
+const packageJson = require('../package.json');
+export const LIB_VERSION = packageJson.version;
0 commit comments