Skip to content

Commit 7308049

Browse files
authored
fix: hardcode config problem fixed in this version
Fix hardcode config
2 parents 621888b + 9a712a5 commit 7308049

7 files changed

Lines changed: 747 additions & 673 deletions

File tree

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# @axonlabs/core
22

3+
## 0.13.1
4+
5+
### Patch Changes
6+
7+
- In previous versions hardcoded config option came back to the Axon core instance but it had some bugs and it wouldn't work.
8+
So the logic of config loading in core edited and the problem fixed and now users can config the Axon core in hardcode mode without config file.
9+
NOTE: Config file support is still ok.
10+
311
## 0.14.0
412

513
### Minor Changes

README.md

Lines changed: 3 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -14,46 +14,10 @@ Currently Axon is 2X faster than Express. :D please checkout [Axon Benchmarks](.
1414

1515
[Axon Documentation](https://axonjslabs.github.io/AxonJs/)
1616

17-
Latest change: (v0.13.0)
17+
Latest change: (v0.13.1)
1818

19-
- Dependency injection
20-
Fixed some problems and dependency injection system redesigned.
21-
1. Register your dependency into the Axon core:
22-
23-
```typescript
24-
// class instance
25-
core.registerDependencyValue('dependencyName', new DependencyClass(arg1, arg2));
26-
27-
// class with factory function (core will run factory function before injection process)
28-
core.registerDependencyFactory('dependencyName2', () => new DependencyClass());
29-
30-
// function
31-
core.registerDependencyValue('dependencyName3', dependencyFunction);
32-
33-
// Also you can register dependencies with name aliases
34-
core.registerDependencyValue(['depClass', 'classDep', 'DB'], new DependencyClass());
35-
```
36-
37-
- NeuronContainer service
38-
Neuron Container is a service to create and handle dependency containers in your project.
39-
Also Axon core is using Neuron Container for dependency injection feature.
40-
41-
```typescript
42-
import { NeuronContainer } from '@axonlabs/core';
43-
44-
const container = new NeuronContainer();
45-
container.registerValue();
46-
container.registerFactory();
47-
container.register();
48-
container.resolve();
49-
container.use();
50-
container.clone();
51-
container.clearScope();
52-
container.checkDependency();
53-
container.override();
54-
container.listDependencies();
55-
container.inspect();
56-
```
19+
- Axon core hardcode config problem
20+
- Some dependencies removed from project and the code and project structure improved.
5721

5822
## Installation 📥
5923

examples/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ import { v1Routes } from './routers/v1';
77
import { v2Routes } from './routers/v2';
88
import { LogPluginTest } from './plugins/log';
99

10-
const core = Axon();
10+
const core = Axon({
11+
DEBUG: true
12+
});
1113

1214
interface Params {
1315
id?: string;

0 commit comments

Comments
 (0)