1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-10 07:55:21 +02:00

Upgrade Biome and refactor JavaScript template literals

- Update @biomejs/biome to latest version with caret (^) notation
- Refactor AI query and chat controllers to use template literals
- Standardize npm scripts formatting in package.json
This commit is contained in:
Josh Pigford 2025-03-11 11:54:47 -05:00
parent e1af36dbd8
commit 50be73fbb8
4 changed files with 9 additions and 9 deletions

View file

@ -33,7 +33,7 @@ export default class extends Controller {
if (data.success) {
this.outputTarget.textContent = data.response
} else {
this.outputTarget.textContent = "Error: " + (data.response || "Something went wrong. Please try again.")
this.outputTarget.textContent = `Error: ${data.response || "Something went wrong. Please try again."}`
}
} catch (error) {
console.error("AI Query error:", error)

View file

@ -63,7 +63,7 @@ export default class extends Controller {
// Reset height to calculate proper scrollHeight
input.style.height = 'auto'
// Set new height based on content
input.style.height = (input.scrollHeight) + 'px'
input.style.height = `${input.scrollHeight}px`
// Cap at 150px max height
if (input.scrollHeight > 150) {
input.style.height = '150px'

2
package-lock.json generated
View file

@ -9,7 +9,7 @@
"version": "1.0.0",
"license": "ISC",
"devDependencies": {
"@biomejs/biome": "1.9.3"
"@biomejs/biome": "^1.9.3"
}
},
"node_modules/@biomejs/biome": {

View file

@ -1,17 +1,17 @@
{
"devDependencies": {
"@biomejs/biome": "1.9.3"
"@biomejs/biome": "^1.9.3"
},
"name": "maybe",
"version": "1.0.0",
"description": "The OS for your personal finances",
"scripts": {
"style:check": "biome check",
"style:fix":"biome check --write",
"lint": "biome lint",
"lint:fix" : "biome lint --write",
"format:check" : "biome format",
"format" : "biome format --write"
"style:fix": "biome check --write",
"lint": "biome lint",
"lint:fix": "biome lint --write",
"format:check": "biome format",
"format": "biome format --write"
},
"author": "",
"license": "ISC"