Init: RoggioApp Architecture, Prisma Schema, API MVP

This commit is contained in:
Clara Zetkin
2026-04-26 19:42:42 +02:00
commit 193b29e8a9
5256 changed files with 1446953 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
import { cloneMethod, hasCloneMethod } from '../../symbols.js';
const safeObjectDefineProperty = Object.defineProperty;
export class Value {
constructor(value_, context, customGetValue = undefined) {
this.value_ = value_;
this.context = context;
this.hasToBeCloned = customGetValue !== undefined || hasCloneMethod(value_);
this.readOnce = false;
if (this.hasToBeCloned) {
safeObjectDefineProperty(this, 'value', { get: customGetValue !== undefined ? customGetValue : this.getValue });
}
else {
this.value = value_;
}
}
getValue() {
if (this.hasToBeCloned) {
if (!this.readOnce) {
this.readOnce = true;
return this.value_;
}
return this.value_[cloneMethod]();
}
return this.value_;
}
}