Releases: actionhero/actionhero
Releases · actionhero/actionhero
v27.0.0
Spec Helper Type changes
It's now much easier to get the types of your response from specHelper.runAction<Action>()
and specHelper.runTask<Task>()
!
Just provide your Action or Task Class!
// In `__tests__/actions/randomNumber.ts`
import { Process, specHelper } from "actionhero";
import { RandomNumber } from "../../src/actions/randomNumber";
describe("Action: randomNumber", () => {
const actionhero = new Process();
beforeAll(async () => await actionhero.start());
afterAll(async () => await actionhero.stop());
test("generates random numbers", async () => {
// now "randomNumber" is typed properly as a number
const { randomNumber } = await specHelper.runAction<RandomNumber>(
"randomNumber"
);
expect(randomNumber).toBeGreaterThan(0);
expect(randomNumber).toBeLessThan(1);
});
});
Version 27 also removed i18n
and uglify
from Actionhero
Localization Removal
- Remove any
/locales/*
files you have, and move that text content into your Actions and Tasks - Remove any instances if
connection.localize()
in your code - this method is removed
Configuration
- In
src/config/api.ts
:- Add
config.general.welcomeMessage = 'Welcome to the Actionhero API!'
or similar message - Remove
config.general.paths.locale
- Add
- In
src/config/errors.ts
:- Remove all instances of
data.connection.localize
and use regular JS strings
- Remove all instances of
Minified Websocket Client Library Removed
ActionheroWebsocketClient.min.js
will no longer be generated in your Actionhero projects. Most users include /public/javascript/ActionheroWebsocketClient.js
in their build and it is compiled into their react or angular project... or cached and minified by their CDN. Minifiying this client-side javascript is now outside of the scope of Actionhero.
v26.1.3
Update dependencies, including support for ws@v8
v26.1.2
v26.1.1
Update Dependencies
v26.1.0
v26.0.9
v26.0.8
v26.0.7
v26.0.6
v26.0.5
- Update Dependencies