Skip to content

Commit 891974f

Browse files
committed
@atlassian/xencoding -> xencoding
1 parent b1f2ac4 commit 891974f

3 files changed

Lines changed: 18 additions & 9 deletions

File tree

.github/workflows/package-validation.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
run: |
5151
cd test-project
5252
cat > test.mjs << 'EOF'
53-
import { encode, decode } from '@atlassian/xencoding';
53+
import { encode, decode } from 'xencoding';
5454
5555
// Test basic functionality
5656
const encoded = encode('test', 123, 'data');

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Xencoding
22

3-
[![Atlassian license](https://img.shields.io/badge/license-Apache%202.0-blue.svg?style=flat-square)](LICENSE) [![npm version](https://img.shields.io/npm/v/@atlassian/xencoding.svg?style=flat-square)](https://www.npmjs.com/package/@atlassian/xencoding) [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](CONTRIBUTING.md)
3+
[![Atlassian license](https://img.shields.io/badge/license-Apache%202.0-blue.svg?style=flat-square)](LICENSE) [![npm version](https://img.shields.io/npm/v/xencoding.svg?style=flat-square)](https://www.npmjs.com/package/xencoding) [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](CONTRIBUTING.md)
44

55
Xencoding is a lexicographical encoding library that converts mixed-type data (strings and numbers) into sortable string keys. This enables efficient range queries and prefix matching in key-value stores\databases (i.e DynamoDB), and other systems that rely on lexicographical ordering.
66

@@ -26,7 +26,7 @@ Xencoding offers several advantages over alternative encoding libraries like [ch
2626
### Basic Encoding and Decoding
2727

2828
```typescript
29-
import { encode, decode } from '@atlassian/xencoding';
29+
import { encode, decode } from 'xencoding';
3030

3131
// Encode mixed types into a sortable string
3232
const key = encode('user', 42, 'profile');
@@ -40,7 +40,7 @@ console.log(values); // ['user', 42, 'profile']
4040
### Lexicographical Ordering
4141

4242
```typescript
43-
import { encode } from '@atlassian/xencoding';
43+
import { encode } from 'xencoding';
4444

4545
// Create keys that sort correctly
4646
const keys = [
@@ -64,7 +64,7 @@ console.log(sorted);
6464
### Prefix Matching
6565

6666
```typescript
67-
import { encode } from '@atlassian/xencoding';
67+
import { encode } from 'xencoding';
6868

6969
// Create a prefix for queries
7070
const prefix = encode('app', 'deployment');
@@ -89,7 +89,7 @@ console.log(matchingKeys);
8989
### Working with Negative Numbers
9090

9191
```typescript
92-
import { encode, decode } from '@atlassian/xencoding';
92+
import { encode, decode } from 'xencoding';
9393

9494
// Negative numbers are supported and sort correctly
9595
const keys = [
@@ -107,13 +107,13 @@ console.log(keys.sort());
107107
## Installation
108108

109109
```bash
110-
yarn add @atlassian/xencoding
110+
yarn add xencoding
111111
```
112112

113113
Or with npm:
114114

115115
```bash
116-
npm install @atlassian/xencoding
116+
npm install xencoding
117117
```
118118

119119
## API Documentation

package.json

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,20 @@
11
{
2-
"name": "@atlassian/xencoding",
2+
"name": "xencoding",
33
"version": "0.9.0",
44
"main": "dist/index.js",
55
"types": "dist/index.d.ts",
66
"license": "Apache-2.0",
77
"description": "Lexicographical encoding library",
88
"author": "Atlassian",
9+
"keywords": [
10+
"encoding",
11+
"lexicographical",
12+
"lexicographic",
13+
"lexicographic encoding",
14+
"lexicographical encoding",
15+
"xencoding"
16+
],
17+
"public": true,
918
"contributors": [
1019
{
1120
"name": "Daniel Hreben",

0 commit comments

Comments
 (0)