DEV Community

sugaiketadao
sugaiketadao

Posted on

Why Go Vanilla? — I built a lightweight Java framework for Japan's "SI" projects (third attempt in 10 years) #11

Introduction

In articles #02 through #10, I introduced the design and features of the SIcore framework. In this final installment, I want to step back and explain the philosophy behind every design decision I've described — why I built it with vanilla (plain Java, JavaScript, and HTML).

SIcore uses no annotations in Java, no JavaScript framework, no template engine for HTML, and no Bootstrap or Tailwind for CSS — just a hand-written 400-line stylesheet.

Going vanilla is a practical choice that pays off in two concrete ways: compatibility with AI code generation and a design that beginners and junior developers can actually learn from.

What "Vanilla" Means Here

Here's a summary of what SIcore deliberately does not use:

Layer What's omitted SIcore's alternative
Java Spring Boot, annotations, DI Direct URL-to-class mapping (#02), reflection
Java (SQL) MyBatis, JPA, XML definitions SQL written directly in Java — SqlBuilder / SqlConst (#10)
Java (data) Entity / DTO / Bean Map-based design — Io class (#07)
JavaScript React, Vue, Angular Vanilla JS + framework utilities
HTML JSP, Thymeleaf, template engines Static HTML + JSON communication (#03, #04)
CSS Bootstrap, Tailwind Custom 400-line stylesheet (#08)
Server Tomcat, Jetty JDK standard HttpServer

In short: enterprise business apps work with nothing beyond the JDK and browser standards.

This isn't a philosophical stance. It's the result of chasing practical outcomes.

Benefit: Plays Well with AI Code Generation

As I mentioned in #01, a design that's beginner-friendly turns out to also be AI-friendly. Here's why.

Unified patterns

Every screen and every process in SIcore follows the same pattern.

JavaScript side:

const req = PageUtil.getValues();
const res = await HttpUtil.callJsonService('/services/module/ClassName', req);
PageUtil.setValues(res);
Enter fullscreen mode Exit fullscreen mode

Java side:

public void doExecute(Io io) throws Exception {
    IoItems row = SqlUtil.selectOne(getDbConn(), LOAD_SQL.bind(io));
    io.putAll(row);
}
Enter fullscreen mode Exit fullscreen mode

Three files — HTML, JS, Java — and one screen works. No routing config, no bean definitions.

AI performs better when patterns are consistent. SIcore documents its coding patterns (21-event-coding-pattern.md), and loading that document into the AI's context produces highly accurate business code.

Lower token consumption

AI tools like GitHub Copilot have limits on how much code (tokens) they can hold in context.

Spring Boot is well-represented in AI training data, but version drift is significant — models generate outdated code or misread project-specific configurations. A custom framework doesn't exist in training data at all, so it must be passed as context every time. But that's only a problem if the context is large.

SIcore's core is small (Java ~5,000 lines, JavaScript ~2,000 lines), and the API reference documentation is compressed specifically for AI use. The entire framework can fit in a reasonable context window.

No magic

Annotations, DI, AOP — these are mechanisms where things happen "automatically" behind the scenes. AI knows these concepts in the abstract, but without the actual code in context, it can only guess at what your project-specific setup does.

In SIcore, the full execution flow is traceable in code. How a URL becomes a class name (#02), how HTML and JSON are transformed (#04) — all of it is readable. When generating code, AI never needs to infer invisible behavior.

The same applies to SQL. Because SIcore writes SQL directly in Java (#10), AI can see exactly what query runs — no XML-to-code linkage to trace.

Works for beginners too

What's easy for AI is easy for humans who are just starting out.

Unified patterns mean you always know what to write next. No magic means you can follow why something works. SQL in code means you can see what data flows where. These are ideal conditions for learning enterprise app development.

"Run it, then read it" is a valid learning strategy here. Someone with basic Java knowledge can start writing business code within days. (In theory. 🤞)

Welcoming AI as a New Kind of Developer

Frameworks have always been built for human users. But today, AI has joined the development team as a new kind of developer.

SIcore chose not to hand AI tools designed for humans but to design from scratch with AI as a first-class user. Choosing vanilla is the answer to that question.

Series Recap

# Topic One-liner
01 Motivation Beginner-friendly design turned out to be AI-friendly
02 Direct URL mapping URL = class name. Zero routing config
03 JSON-only Server never returns HTML
04 Mockup = implementation Add a name attribute and the mockup becomes production code
05 Dynamic list rendering Template row auto-expands array data
06 Custom HTML attributes data-* attributes for common patterns
07 Map-based data design No entities. Just Maps
08 Single-file CSS 400 lines covers an entire business app
09 Client-side data + JWT Stateless design, no server sessions
10 SQL directly in Java No XML. SQL injection protection built in
11 Why go vanilla? (this article) The design philosophy behind it all

Laid out like this, every decision connects along one axis: adding nothing unnecessary. By not adding, the result became a framework that AI handles well and beginners can actually read.

Closing Thoughts

"Vanilla" sounds old-fashioned. Inefficient, maybe. But in practice, vanilla is a strength in the age of AI-assisted development.

  • Code that AI understands → higher generation accuracy
  • Code that beginners can read → junior devs become productive faster, with AI's help

Going vanilla isn't "old." It's a deliberate choice to add nothing unnecessary. A framework's value is defined not by what it adds, but by what it leaves out — that's the conclusion I reached after building this for the third time in ten years.

You can run the sample code directly in VS Code with just a browser. Setup instructions are in the README. If any of this sounds interesting, I'd love for you to give it a try.

SIcore Framework Links

All code and documentation is publicly available:

Related Articles


Thanks for reading!
If you found this useful, reactions and comments are always appreciated. ❤️

Top comments (0)