Skip to content

Commit 0aae816

Browse files
committed
💎 (Life cycle): update order
1 parent 5bd149a commit 0aae816

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

.npmignore

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
.DS_Store
2-
.idea
2+
.idea/
33
*.iml
44
npm-debug.log
55
yarn-error.log
6-
node_modules
6+
node_modules/
77
.github
8-
src
8+
src/
99
.eslintrc.js
1010
tsconfig.json

dist/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ class RNBPlugin {
4444
try {
4545
await (0, child_process_1.execSync)(`yarn add -D ${this.packageUrl}${this.version}`, { stdio: 'pipe' });
4646
await this.lifecycle.onInstall(value, previousValues);
47-
await (0, child_process_1.execSync)(`yarn remove ${this.packageUrl}`, { stdio: 'pipe' });
4847
await this.lifecycle.afterInstall(value, previousValues);
48+
await (0, child_process_1.execSync)(`yarn remove ${this.packageUrl}`, { stdio: 'pipe' });
4949
}
5050
catch (e) {
5151
console.error(e);

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@thecodingmachine/rnb-toolbox",
3-
"version": "1.0.0-rc.1",
3+
"version": "1.0.0",
44
"description": "Help all @thecodingmachine/react-native-boilerplate plugins creators to build awesome custom plugins",
55
"repository": {
66
"type": "git",

src/RNBPlugin/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,11 +127,11 @@ export class RNBPlugin {
127127
{ stdio: 'pipe' },
128128
);
129129
await this.lifecycle.onInstall(value, previousValues);
130+
await this.lifecycle.afterInstall(value, previousValues);
130131
await execSync(
131132
`yarn remove ${this.packageUrl}`,
132133
{ stdio: 'pipe' },
133134
);
134-
await this.lifecycle.afterInstall(value, previousValues);
135135
} catch (e) {
136136
console.error(e);
137137
}

0 commit comments

Comments
 (0)