@lindle/sharepoint_requests 0.1.9-beta.0 → 0.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/root/index.d.ts +7 -7
- package/dist/root/instance.d.ts +3 -0
- package/dist/sharepoint_requests.cjs.development.js +248 -307
- package/dist/sharepoint_requests.cjs.development.js.map +1 -1
- package/dist/sharepoint_requests.cjs.production.min.js +1 -1
- package/dist/sharepoint_requests.cjs.production.min.js.map +1 -1
- package/dist/sharepoint_requests.esm.js +248 -307
- package/dist/sharepoint_requests.esm.js.map +1 -1
- package/package.json +3 -3
- package/src/root/index.ts +52 -37
- package/src/root/instance.ts +20 -0
- package/src/{types/index.ts → types.ts} +342 -342
- package/dist/root/request/digest.d.ts +0 -7
- package/dist/root/request/get.d.ts +0 -13
- package/src/root/request/digest.ts +0 -25
- package/src/root/request/get.ts +0 -44
- /package/dist/{types/index.d.ts → types.d.ts} +0 -0
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@ This package is a TypeScript library for interacting with SharePoint REST APIs.
|
|
|
7
7
|
Install the package using npm:
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
|
-
npm install
|
|
10
|
+
npm install @lindle/sharepoint_requests
|
|
11
11
|
```
|
|
12
12
|
|
|
13
13
|
## Usage
|
|
@@ -15,7 +15,7 @@ npm install sharepoint-requests
|
|
|
15
15
|
### Create a SharePoint Request Instance
|
|
16
16
|
|
|
17
17
|
```typescript
|
|
18
|
-
import createBase from '
|
|
18
|
+
import createBase from '@lindle/sharepoint_requests';
|
|
19
19
|
|
|
20
20
|
const sharepoint = createBase().create({
|
|
21
21
|
baseURL: 'https://your-sharepoint-site.com',
|
package/dist/root/index.d.ts
CHANGED
|
@@ -23,16 +23,16 @@ declare class HTTPSharePointRequests<T extends {
|
|
|
23
23
|
}>;
|
|
24
24
|
};
|
|
25
25
|
from<K extends Extract<keyof T['LISTS'], string>>(listName: K, sharepoint_ver?: SHAREPOINT_VER): {
|
|
26
|
-
create: (data: ListData) => Promise<AxiosResponse<any, any>>;
|
|
26
|
+
create: (data: ListData) => Promise<AxiosResponse<any, any, {}>>;
|
|
27
27
|
get: (options?: Options<T['LISTS'][K]>) => Promise<{
|
|
28
28
|
data: (T["LISTS"][K] & Partial<SPItem>)[];
|
|
29
29
|
meta: {
|
|
30
30
|
url: URL;
|
|
31
31
|
};
|
|
32
32
|
}>;
|
|
33
|
-
update: (id: ItemID, data: ListData, digest?: string) => Promise<AxiosResponse<any, any>>;
|
|
34
|
-
delete: (id: ItemID) => Promise<AxiosResponse<any, any>>;
|
|
35
|
-
createFile: (props: CreateFileProps) => Promise<AxiosResponse<any, any>>;
|
|
33
|
+
update: (id: ItemID, data: ListData, digest?: string) => Promise<AxiosResponse<any, any, {}>>;
|
|
34
|
+
delete: (id: ItemID) => Promise<AxiosResponse<any, any, {}>>;
|
|
35
|
+
createFile: (props: CreateFileProps) => Promise<AxiosResponse<any, any, {}>>;
|
|
36
36
|
fields: (options?: Field_Options<T['LISTS'][K]>) => {
|
|
37
37
|
get: () => Promise<any>;
|
|
38
38
|
};
|
|
@@ -48,8 +48,8 @@ declare class HTTPSharePointRequests<T extends {
|
|
|
48
48
|
};
|
|
49
49
|
}>;
|
|
50
50
|
};
|
|
51
|
-
users: {
|
|
52
|
-
get: (
|
|
51
|
+
users(options?: Options<any>): {
|
|
52
|
+
get: () => Promise<{
|
|
53
53
|
data: any[];
|
|
54
54
|
meta: {
|
|
55
55
|
url: URL;
|
|
@@ -99,7 +99,7 @@ declare class HTTPSharePointRequests<T extends {
|
|
|
99
99
|
d: {
|
|
100
100
|
SendEmail: null;
|
|
101
101
|
};
|
|
102
|
-
}, any>>;
|
|
102
|
+
}, any, {}>>;
|
|
103
103
|
};
|
|
104
104
|
private sendEmail;
|
|
105
105
|
private typeAhead;
|