<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Trinmar Boado</title>
    <description>The latest articles on DEV Community by Trinmar Boado (@trinly01).</description>
    <link>https://dev.to/trinly01</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F257934%2F6725e89e-de78-4900-b708-e4bbb093e5c9.jpg</url>
      <title>DEV Community: Trinmar Boado</title>
      <link>https://dev.to/trinly01</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/trinly01"/>
    <language>en</language>
    <item>
      <title># Talaan Chain System 🔗</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Sun, 19 Oct 2025 14:57:40 +0000</pubDate>
      <link>https://dev.to/trinly01/-talaan-chain-system-51kb</link>
      <guid>https://dev.to/trinly01/-talaan-chain-system-51kb</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Lightweight, tamperproof audit logging without blockchain complexity&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Talaan Chain provides cryptographically-secured audit trails using hash chaining, distributed validation, and JWT signatures. It's designed for organizations that need blockchain-level integrity without the overhead.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Problem with Blockchain for Internal Auditing
&lt;/h2&gt;

&lt;p&gt;Blockchain is powerful but impractical for most organizational use cases:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph "Blockchain Challenges"
        B1[High Infrastructure Cost&amp;lt;br/&amp;gt;$50K-500K+ annually]
        B2[Slow Performance&amp;lt;br/&amp;gt;3-15 transactions/sec]
        B3[Complex Setup&amp;lt;br/&amp;gt;6-12 months]
        B4[Specialized Skills&amp;lt;br/&amp;gt;Blockchain developers]
        B5[Public by Design&amp;lt;br/&amp;gt;Limited privacy control]
    end

    subgraph "What Organizations Actually Need"
        N1[Tamperproof Logs]
        N2[Reasonable Cost]
        N3[Fast Performance]
        N4[Simple Integration]
        N5[Private &amp;amp; Controlled]
    end

    B1 -.-&amp;gt;|Mismatch| N2
    B2 -.-&amp;gt;|Mismatch| N3
    B3 -.-&amp;gt;|Mismatch| N4
    B4 -.-&amp;gt;|Mismatch| N4
    B5 -.-&amp;gt;|Mismatch| N5

    style B1 fill:#E74C3C
    style B2 fill:#E74C3C
    style B3 fill:#E74C3C
    style B4 fill:#E74C3C
    style B5 fill:#E74C3C
    style N1 fill:#50C878
    style N2 fill:#50C878
    style N3 fill:#50C878
    style N4 fill:#50C878
    style N5 fill:#50C878
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;The Reality&lt;/strong&gt;: Most organizations don't need a global, decentralized ledger. They need provable audit trails in a controlled environment.&lt;/p&gt;




&lt;h2&gt;
  
  
  Why Talaan Chain?
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. &lt;strong&gt;Practical Tamperproofing&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Instead of expensive cryptographic hashing (SHA-256), we use FNV-1a with multiple security layers:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph "Defense in Depth"
        L1[Layer 1: Hash Chaining&amp;lt;br/&amp;gt;FNV-1a + Parent Reference]
        L2[Layer 2: Cryptographic Signatures&amp;lt;br/&amp;gt;JWT with Secret Key]
        L3[Layer 3: Distributed Validation&amp;lt;br/&amp;gt;Independent Mirror Servers]
    end

    subgraph "Attack Requirements"
        A1[Modify local database]
        A2[Recompute entire chain]
        A3[Forge JWT signature]
        A4[Compromise ALL mirrors]
        A5[Do it SIMULTANEOUSLY]
    end

    L1 --&amp;gt; A1 &amp;amp; A2
    L2 --&amp;gt; A3
    L3 --&amp;gt; A4 &amp;amp; A5

    Result[Practically Impossible&amp;lt;br/&amp;gt;for Internal Threats]

    A1 &amp;amp; A2 &amp;amp; A3 &amp;amp; A4 &amp;amp; A5 --&amp;gt; Result

    style L1 fill:#4A90E2
    style L2 fill:#50C878
    style L3 fill:#9B59B6
    style Result fill:#F39C12
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Why This Works:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The combination of hash chaining + cryptographic signatures + distributed validation makes tampering extremely difficult in controlled environments. You'd need to:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Break the chain&lt;/strong&gt;: Modify entry → recompute all downstream hashes&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Forge signatures&lt;/strong&gt;: Create valid JWT without secret key&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Synchronize attack&lt;/strong&gt;: Compromise 3+ independent servers simultaneously&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Avoid detection&lt;/strong&gt;: Complete within 15-second validation window&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This is &lt;strong&gt;practically impossible&lt;/strong&gt; for insider threats (the real risk in most organizations).&lt;/p&gt;

&lt;h3&gt;
  
  
  2. &lt;strong&gt;10x Faster, 90% Cheaper&lt;/strong&gt;
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph LR
    subgraph "Blockchain"
        BC1[SHA-256 Hashing&amp;lt;br/&amp;gt;~0.50ms per operation]
        BC2[Consensus Protocol&amp;lt;br/&amp;gt;Network overhead]
        BC3[Node Infrastructure&amp;lt;br/&amp;gt;$50K+ annual cost]
    end

    subgraph "Talaan Chain"
        TC1[FNV-1a Hashing&amp;lt;br/&amp;gt;~0.05ms per operation]
        TC2[No Consensus&amp;lt;br/&amp;gt;Direct validation]
        TC3[Standard Database&amp;lt;br/&amp;gt;$2-5K annual cost]
    end

    BC1 -.-&amp;gt;|10x slower| TC1
    BC2 -.-&amp;gt;|Network delay| TC2
    BC3 -.-&amp;gt;|25x costlier| TC3

    style BC1 fill:#E74C3C
    style BC2 fill:#E74C3C
    style BC3 fill:#E74C3C
    style TC1 fill:#50C878
    style TC2 fill:#50C878
    style TC3 fill:#50C878
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Performance Comparison:&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Metric&lt;/th&gt;
&lt;th&gt;Blockchain&lt;/th&gt;
&lt;th&gt;Talaan Chain&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Hash Speed&lt;/td&gt;
&lt;td&gt;0.50ms (SHA-256)&lt;/td&gt;
&lt;td&gt;0.05ms (FNV-1a)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Throughput&lt;/td&gt;
&lt;td&gt;3-15 TPS&lt;/td&gt;
&lt;td&gt;150+ TPS&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Setup Time&lt;/td&gt;
&lt;td&gt;6-12 months&lt;/td&gt;
&lt;td&gt;2-3 days&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Infrastructure&lt;/td&gt;
&lt;td&gt;Specialized nodes&lt;/td&gt;
&lt;td&gt;Standard database&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Annual Cost&lt;/td&gt;
&lt;td&gt;$50K-500K+&lt;/td&gt;
&lt;td&gt;$2-10K&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  3. &lt;strong&gt;Simple Integration&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Talaan Chain works with your existing database through standard triggers:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sequenceDiagram
    participant DB as Your Database
    participant Talaan as Talaan Chain
    participant Mirror as Mirror Server

    DB-&amp;gt;&amp;gt;Talaan: Record Created/Updated/Deleted
    Note over Talaan: Generate hash&amp;lt;br/&amp;gt;Sign with JWT
    Talaan-&amp;gt;&amp;gt;Talaan: Store in chain
    Talaan-&amp;gt;&amp;gt;Mirror: Sync to mirrors
    Mirror--&amp;gt;&amp;gt;Talaan: Validated

    Note over DB,Mirror: Zero changes to your app code!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;No code changes required.&lt;/strong&gt; Install flows, configure triggers, done.&lt;/p&gt;

&lt;p&gt;Compare to blockchain:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Rewrite data layer&lt;/li&gt;
&lt;li&gt;Implement blockchain APIs&lt;/li&gt;
&lt;li&gt;Manage wallet keys&lt;/li&gt;
&lt;li&gt;Handle consensus logic&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  4. &lt;strong&gt;Distributed Validation Without Decentralization&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;You don't need a global network. You need trustworthy validators:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph "Your Organization"
        Primary[(Primary Database&amp;lt;br/&amp;gt;Your Server)]
    end

    subgraph "Independent Validators"
        Mirror1[(Audit Department&amp;lt;br/&amp;gt;Separate Network)]
        Mirror2[(External Auditor&amp;lt;br/&amp;gt;Different Organization)]
        Mirror3[(Regulatory Body&amp;lt;br/&amp;gt;Government Server)]
    end

    Primary --&amp;gt;|Real-time Sync| Mirror1
    Primary --&amp;gt;|Real-time Sync| Mirror2
    Primary --&amp;gt;|Real-time Sync| Mirror3

    Mirror1 -.-&amp;gt;|Cross-Validate| Mirror2
    Mirror2 -.-&amp;gt;|Cross-Validate| Mirror3
    Mirror3 -.-&amp;gt;|Cross-Validate| Mirror1

    Attacker[Internal Bad Actor] -.-&amp;gt;|Attempts Tampering| Primary
    Primary -.-&amp;gt;|Mismatch Detected| Alert[🚨 Automatic Alert]
    Mirror1 -.-&amp;gt;|Validates Against| Alert
    Mirror2 -.-&amp;gt;|Validates Against| Alert
    Mirror3 -.-&amp;gt;|Validates Against| Alert

    style Primary fill:#4A90E2
    style Mirror1 fill:#50C878
    style Mirror2 fill:#50C878
    style Mirror3 fill:#50C878
    style Attacker fill:#E74C3C
    style Alert fill:#F39C12
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Key Insight&lt;/strong&gt;: In controlled environments (organizations, governments), you have trusted parties who can run independent validators. You don't need anonymous global consensus.&lt;/p&gt;




&lt;h2&gt;
  
  
  How It Works
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Hash Chaining Explained
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph LR
    subgraph "Entry 1 (Genesis)"
        E1["parent_hash: 'genesis'&amp;lt;br/&amp;gt;payload: data&amp;lt;br/&amp;gt;current_hash: abc123"]
    end

    subgraph "Entry 2"
        E2["parent_hash: abc123&amp;lt;br/&amp;gt;payload: data&amp;lt;br/&amp;gt;current_hash: def456"]
    end

    subgraph "Entry 3"
        E3["parent_hash: def456&amp;lt;br/&amp;gt;payload: data&amp;lt;br/&amp;gt;current_hash: ghi789"]
    end

    E1 --&amp;gt;|Hash includes parent| E2
    E2 --&amp;gt;|Hash includes parent| E3

    Tamper["Try to modify Entry 2"] -.-&amp;gt;|Changes hash| E2
    E2 -.-&amp;gt;|Breaks chain| E3
    E3 -.-&amp;gt;|Validation fails| Detected["Tampering Detected ⚠️"]

    style E1 fill:#50C878
    style E2 fill:#4A90E2
    style E3 fill:#9B59B6
    style Tamper fill:#E74C3C
    style Detected fill:#F39C12
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Each entry includes:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Hash of its own payload (data)&lt;/li&gt;
&lt;li&gt;Hash of previous entry (parent_hash)&lt;/li&gt;
&lt;li&gt;Combined into current_hash&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;To tamper successfully, attacker must:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Recompute current entry hash&lt;/li&gt;
&lt;li&gt;Recompute ALL subsequent entry hashes&lt;/li&gt;
&lt;li&gt;Update all mirrors simultaneously&lt;/li&gt;
&lt;li&gt;Complete before next validation cycle (15 seconds)&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  FNV-1a: Fast Enough for Security?
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Question&lt;/strong&gt;: "Isn't FNV-1a a non-cryptographic hash? Can't it be broken?"&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Answer&lt;/strong&gt;: Yes, it's non-cryptographic. But that's not the weakness you think it is.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph "What Makes Blockchain Secure?"
        BC1[Cryptographic Hash&amp;lt;br/&amp;gt;SHA-256]
        BC2[Global Network]
        BC3[Proof of Work]
        BC4[Economic Incentives]
    end

    subgraph "What Makes Talaan Secure?"
        TC1[Fast Hash&amp;lt;br/&amp;gt;FNV-1a]
        TC2[Hash Chaining]
        TC3[Distributed Validators]
        TC4[JWT Signatures]
        TC5[Access Control]
    end

    BC1 -.-&amp;gt;|Needed because| BC2
    BC2 -.-&amp;gt;|Requires| BC3
    BC3 -.-&amp;gt;|Sustained by| BC4

    TC1 --&amp;gt;|Combined with| TC2
    TC2 --&amp;gt;|Combined with| TC3
    TC3 --&amp;gt;|Combined with| TC4
    TC4 --&amp;gt;|Combined with| TC5

    Result1[Secure against&amp;lt;br/&amp;gt;Anonymous Attackers]
    Result2[Secure against&amp;lt;br/&amp;gt;Internal Threats]

    BC1 &amp;amp; BC2 &amp;amp; BC3 &amp;amp; BC4 --&amp;gt; Result1
    TC1 &amp;amp; TC2 &amp;amp; TC3 &amp;amp; TC4 &amp;amp; TC5 --&amp;gt; Result2

    style BC1 fill:#E74C3C
    style Result1 fill:#9B59B6
    style TC5 fill:#50C878
    style Result2 fill:#50C878
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Context Matters&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Blockchain&lt;/strong&gt;: Faces anonymous attackers with unlimited computing power → needs cryptographic security&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Talaan Chain&lt;/strong&gt;: Faces internal threats with limited access → needs layered defense&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;The Real Security&lt;/strong&gt;: It's not about hash strength alone. It's about:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Chain Dependency&lt;/strong&gt;: Can't modify one entry without breaking all subsequent ones&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Distributed Copies&lt;/strong&gt;: Need to compromise multiple independent systems&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Time Constraints&lt;/strong&gt;: Must complete attack within validation window&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Audit Trails&lt;/strong&gt;: Every access attempt is logged&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  System Architecture
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph "Your Application Layer"
        APP[Web/Mobile App]
        API[REST API]
    end

    subgraph "Database Layer"
        DB[(Primary Database)]
        TRIGGER[Database Triggers]
    end

    subgraph "Talaan Chain Layer"
        LOGGER[Chain Logger&amp;lt;br/&amp;gt;Creates entries]
        STORAGE[(Chain Storage&amp;lt;br/&amp;gt;talaan_chain)]
        MONITOR[Chain Monitor&amp;lt;br/&amp;gt;Validates every 15s]
    end

    subgraph "Validation Layer"
        MIRROR1[(Mirror 1)]
        MIRROR2[(Mirror 2)]
        MIRROR3[(Mirror 3)]
        VALIDATOR[Item Validator&amp;lt;br/&amp;gt;Public API]
    end

    APP --&amp;gt; API
    API --&amp;gt; DB
    DB --&amp;gt; TRIGGER
    TRIGGER -.-&amp;gt;|Auto-trigger| LOGGER
    LOGGER --&amp;gt; STORAGE
    LOGGER -.-&amp;gt;|Webhook| MIRROR1 &amp;amp; MIRROR2 &amp;amp; MIRROR3
    STORAGE --&amp;gt; MONITOR
    MONITOR -.-&amp;gt;|Validates| MIRROR1 &amp;amp; MIRROR2 &amp;amp; MIRROR3
    STORAGE -.-&amp;gt;|Query| VALIDATOR

    style APP fill:#4A90E2
    style DB fill:#4A90E2
    style LOGGER fill:#50C878
    style STORAGE fill:#50C878
    style MONITOR fill:#F39C12
    style VALIDATOR fill:#9B59B6
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Use Cases
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Financial Transactions
&lt;/h3&gt;

&lt;p&gt;Track every transaction with immutable audit trails:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sequenceDiagram
    participant User as User
    participant System as App
    participant Talaan as Talaan Chain
    participant Auditor as Auditor

    User-&amp;gt;&amp;gt;System: Transfer $10,000
    System-&amp;gt;&amp;gt;System: Process transaction
    System-&amp;gt;&amp;gt;Talaan: Log transaction
    Note over Talaan: Hash + Chain + Sign
    Talaan-&amp;gt;&amp;gt;Talaan: Store immutably
    Talaan--&amp;gt;&amp;gt;System: Confirmed
    System--&amp;gt;&amp;gt;User: Success

    Note over System: 6 months later...
    Auditor-&amp;gt;&amp;gt;Talaan: Query transaction history
    Talaan-&amp;gt;&amp;gt;Talaan: Validate chain
    Talaan--&amp;gt;&amp;gt;Auditor: ✅ Original: $10,000&amp;lt;br/&amp;gt;✅ No modifications&amp;lt;br/&amp;gt;✅ Hash verified
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Prevents:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Unauthorized transaction modifications&lt;/li&gt;
&lt;li&gt;Deleted audit logs&lt;/li&gt;
&lt;li&gt;Backdated entries&lt;/li&gt;
&lt;li&gt;"System error" excuses&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Document Management
&lt;/h3&gt;

&lt;p&gt;Prove document authenticity and track changes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;stateDiagram-v2
    [*] --&amp;gt; Draft: Document Created
    Draft --&amp;gt; Review: Submitted
    Review --&amp;gt; Approved: Manager Signs
    Approved --&amp;gt; Published: Released

    Draft --&amp;gt; Talaan1: ✅ Logged
    Review --&amp;gt; Talaan2: ✅ Logged
    Approved --&amp;gt; Talaan3: ✅ Logged
    Published --&amp;gt; Talaan4: ✅ Logged

    Approved --&amp;gt; Tamper: Attempt Modification
    Tamper --&amp;gt; Detected: Hash Mismatch
    Detected --&amp;gt; [*]: ❌ Rejected

    Published --&amp;gt; [*]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Enables:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Version history verification&lt;/li&gt;
&lt;li&gt;Non-repudiation (can't deny signing)&lt;/li&gt;
&lt;li&gt;Forgery detection&lt;/li&gt;
&lt;li&gt;Complete change audit&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. Access Control Logs
&lt;/h3&gt;

&lt;p&gt;Monitor and prove system access:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph LR
    subgraph "Access Events"
        E1[Login]
        E2[Permission Change]
        E3[Data Export]
        E4[Admin Action]
    end

    subgraph "Talaan Chain"
        L1[✅ Logged]
        L2[✅ Chained]
        L3[✅ Validated]
    end

    subgraph "Security Benefits"
        B1[Detect Unauthorized Access]
        B2[Prove Compliance]
        B3[Forensic Investigation]
        B4[Non-Repudiation]
    end

    E1 &amp;amp; E2 &amp;amp; E3 &amp;amp; E4 --&amp;gt; L1
    L1 --&amp;gt; L2
    L2 --&amp;gt; L3
    L3 --&amp;gt; B1 &amp;amp; B2 &amp;amp; B3 &amp;amp; B4

    style L1 fill:#50C878
    style L2 fill:#50C878
    style L3 fill:#50C878
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Technical Details
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Core Components
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph "1. Chain Logger"
        L1[Triggered by DB events]
        L2[Reads parent entry]
        L3[Generates hash]
        L4[Signs with JWT]
        L5[Stores &amp;amp; syncs]
    end

    subgraph "2. Mirror Receiver"
        M1[Receives webhook]
        M2[Verifies JWT]
        M3[Validates hash]
        M4[Stores copy]
    end

    subgraph "3. Chain Monitor"
        C1[Runs every 15s]
        C2[Validates chain]
        C3[Checks mirrors]
        C4[Alerts on mismatch]
    end

    subgraph "4. Item Validator"
        V1[Public API]
        V2[Queries history]
        V3[Validates chain]
        V4[Returns proof]
    end

    L1 --&amp;gt; L2 --&amp;gt; L3 --&amp;gt; L4 --&amp;gt; L5
    M1 --&amp;gt; M2 --&amp;gt; M3 --&amp;gt; M4
    C1 --&amp;gt; C2 --&amp;gt; C3 --&amp;gt; C4
    V1 --&amp;gt; V2 --&amp;gt; V3 --&amp;gt; V4

    L5 -.-&amp;gt;|Webhook| M1
    L5 -.-&amp;gt;|Stores| C2
    C2 -.-&amp;gt;|Validates| M4

    style L3 fill:#50C878
    style M3 fill:#50C878
    style C2 fill:#F39C12
    style V3 fill:#9B59B6
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Hash Generation Algorithm
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// 1. Deterministic serialization (sorted keys)&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;serializeJson&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;obj&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;obj&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="k"&gt;typeof&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;object&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nb"&gt;Array&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;isArray&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nb"&gt;Object&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;keys&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;sort&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;reduce&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;sorted&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nx"&gt;sorted&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;sorted&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="p"&gt;},&lt;/span&gt; &lt;span class="p"&gt;{});&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;});&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// 2. FNV-1a hashing (fast, deterministic)&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;fnv1aHash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;hash&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;2166136261&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c1"&gt;// FNV offset basis&lt;/span&gt;
  &lt;span class="k"&gt;for &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;str&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;hash&lt;/span&gt; &lt;span class="o"&gt;^=&lt;/span&gt; &lt;span class="nx"&gt;str&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;charCodeAt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nx"&gt;hash&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;imul&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;hash&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;16777619&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// FNV prime&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;hash&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;toString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;16&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;padStart&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;8&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;0&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// 3. Chain entry hash&lt;/span&gt;
&lt;span class="nx"&gt;current_hash&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;fnv1aHash&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;parent&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;parent_hash&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;fnv1aHash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Chain Entry Structure
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kr"&gt;interface&lt;/span&gt; &lt;span class="nx"&gt;ChainEntry&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;talaan_id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;      &lt;span class="c1"&gt;// UUID&lt;/span&gt;
  &lt;span class="nl"&gt;parent_id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;      &lt;span class="c1"&gt;// Previous entry's talaan_id&lt;/span&gt;
  &lt;span class="nl"&gt;parent_hash&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;    &lt;span class="c1"&gt;// Previous entry's current_hash&lt;/span&gt;
  &lt;span class="nl"&gt;current_hash&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;   &lt;span class="c1"&gt;// This entry's hash&lt;/span&gt;
  &lt;span class="nl"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;$trigger&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;           &lt;span class="c1"&gt;// Event data&lt;/span&gt;
      &lt;span class="na"&gt;event&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;collection&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;key&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;object&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;};&lt;/span&gt;
    &lt;span class="nl"&gt;$accountability&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;    &lt;span class="c1"&gt;// User context&lt;/span&gt;
      &lt;span class="na"&gt;user&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;role&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;ip&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;};&lt;/span&gt;
  &lt;span class="p"&gt;};&lt;/span&gt;
  &lt;span class="nl"&gt;created_at&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;timestamp&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Setup
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Prerequisites
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;PostgreSQL or MySQL database&lt;/li&gt;
&lt;li&gt;Node.js runtime
-the system (or compatible workflow system)&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Deploy Mirrors
&lt;/h3&gt;

&lt;p&gt;Each independent validator runs the mirror receiver:&lt;/p&gt;




&lt;h2&gt;
  
  
  Comparison Summary
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Talaan Chain vs Blockchain
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph LR
    subgraph "Blockchain"
        BC[Public Ledger&amp;lt;br/&amp;gt;Global Consensus&amp;lt;br/&amp;gt;Cryptographic Security&amp;lt;br/&amp;gt;High Cost&amp;lt;br/&amp;gt;Complex Setup]
    end

    subgraph "Talaan Chain"
        TC[Private Ledger&amp;lt;br/&amp;gt;Distributed Validation&amp;lt;br/&amp;gt;Layered Security&amp;lt;br/&amp;gt;Low Cost&amp;lt;br/&amp;gt;Simple Setup]
    end

    subgraph "Best For"
        BC_USE[Cryptocurrency&amp;lt;br/&amp;gt;Public Records&amp;lt;br/&amp;gt;Trustless Systems&amp;lt;br/&amp;gt;Global Networks]
        TC_USE[Internal Audits&amp;lt;br/&amp;gt;Compliance Logs&amp;lt;br/&amp;gt;Organizational Data&amp;lt;br/&amp;gt;Controlled Access]
    end

    BC -.-&amp;gt;|Designed for| BC_USE
    TC -.-&amp;gt;|Designed for| TC_USE

    style BC fill:#E74C3C
    style TC fill:#50C878
    style TC_USE fill:#9B59B6
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Choose Blockchain When:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You need a truly public, permissionless system&lt;/li&gt;
&lt;li&gt;Participants are anonymous and potentially adversarial&lt;/li&gt;
&lt;li&gt;You're handling cryptocurrency or tokenized assets&lt;/li&gt;
&lt;li&gt;You need global consensus without trusted parties&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Choose Talaan Chain When:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You need internal audit trails&lt;/li&gt;
&lt;li&gt;You have trusted validator parties&lt;/li&gt;
&lt;li&gt;You want fast performance and low cost&lt;/li&gt;
&lt;li&gt;You need to integrate with existing systems&lt;/li&gt;
&lt;li&gt;Your data must remain private&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Q: Is FNV-1a secure enough?&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
A: For controlled environments with layered security, yes. The combination of hash chaining + JWT signatures + distributed validation provides practical tamperproofing against internal threats.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: Can I use SHA-256 instead?&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
A: Yes, you can swap the hash function. But for most use cases, the bottleneck is network latency and database operations, not hash speed.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: How many mirrors do I need?&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
A: Minimum 2 (preferably 3+). Each mirror should be controlled by an independent party to prevent collusion.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: What if a mirror goes offline?&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
A: The system continues operating. Offline mirrors sync when they come back online. Having 3+ mirrors provides redundancy.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: Can I verify entries publicly?&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
A: Yes, via the Item Validator API. You can make this fully public or restrict to authenticated users.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: Does this work with any database?&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
A: Yes, any database that supports triggers and JSON fields. Tested with PostgreSQL, MySQL, and MariaDB.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Built for organizations that need blockchain-level integrity without blockchain complexity.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;🔥 Why Talaan Chain? 🔗&lt;br&gt;
Because corruption thrives in the dark — and we’re bringing transparency to light. 💡&lt;/p&gt;

&lt;p&gt;Every log. Every change. Every action.&lt;br&gt;
📜 Recorded. Chained. Tamperproof.&lt;/p&gt;

&lt;p&gt;No more deleted evidence. No more excuses. 🚫&lt;br&gt;
Just truth, accountability, and trust. 💪&lt;/p&gt;

&lt;h1&gt;
  
  
  TalaanChain #TransparencyTech #AntiCorruption #AuditRevolution #DataIntegrity
&lt;/h1&gt;

</description>
      <category>security</category>
      <category>blockchain</category>
      <category>web3</category>
      <category>programming</category>
    </item>
    <item>
      <title># Tamper-Evident Ledger Systems for National Budget Transparency</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Fri, 03 Oct 2025 02:40:34 +0000</pubDate>
      <link>https://dev.to/trinly01/-tamper-evident-ledger-systems-for-national-budget-transparency-nl1</link>
      <guid>https://dev.to/trinly01/-tamper-evident-ledger-systems-for-national-budget-transparency-nl1</guid>
      <description>&lt;h1&gt;
  
  
  Tamper-Evident Ledger Systems for National Budget Transparency
&lt;/h1&gt;

&lt;h2&gt;
  
  
  A Technology-Neutral Framework on Senate Bill 1330
&lt;/h2&gt;

&lt;h3&gt;
  
  
  📋 Project Overview
&lt;/h3&gt;

&lt;p&gt;This contains a comprehensive position paper and framework for implementing Tamper-Evident Ledger Systems (TELS) to combat corruption in the Philippine National Budget. The framework addresses Senate Bill No. 1330 (Philippine National Budget Blockchain Act) with detailed amendments that transform it from a simple blockchain mandate into a robust accountability system.&lt;/p&gt;

&lt;h3&gt;
  
  
  🎯 Mission Statement
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;"To design accountability into the budget system so corruption becomes visible, traceable, punishable, and preventable."&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This is not about "blockchaining the budget" - it's about creating a comprehensive framework where every peso has a clear parent, every change is logged, and corruption becomes suicidal rather than profitable.&lt;/p&gt;

&lt;p&gt;&lt;a id="executive-summary"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🧭 Executive Summary
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What&lt;/strong&gt;: A technology-neutral Tamper-Evident Ledger System (TELS) that uses traditional databases for data storage and an immutable ledger for proof (hashes) to make corruption visible, traceable, punishable, and preventable.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;How&lt;/strong&gt;: Hybrid architecture (databases for data, ledger for verification), real-time oversight for COA, strict penalties, citizen dashboards, multi-sector oversight, and pilot-first rollout.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Why&lt;/strong&gt;: Avoid costly, slow, and privacy-conflicting "blockchain everything" schemes; comply with the Data Privacy Act; achieve transparency with measurable outcomes.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cost/ROI&lt;/strong&gt;: Prioritize government‑run, permissioned ledger to avoid external per‑transaction fees; store data off‑chain and hashes on‑chain to minimize storage costs. See Cost-Benefit section for assumptions and formulas.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Fit&lt;/strong&gt;: Compliant with RA 10173 (Data Privacy), RA 8792 (E-Commerce), RA 10175 (Cybercrime), PD 1445 (Auditing), RA 9346 (no death penalty), RA 9184 (Procurement), RA 11032 (Ease of Doing Business), and EO No. 2 (2016) FOI.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🗂️ Table of Contents
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Executive Summary&lt;/li&gt;
&lt;li&gt;Objectives and Scope&lt;/li&gt;
&lt;li&gt;Key Statistics&lt;/li&gt;
&lt;li&gt;Critical Design Principles&lt;/li&gt;
&lt;li&gt;Agency Integrations &amp;amp; Standards&lt;/li&gt;
&lt;li&gt;Core Framework Components&lt;/li&gt;
&lt;li&gt;Technical Architecture (Hybrid Model)&lt;/li&gt;
&lt;li&gt;Cost-Benefit Analysis&lt;/li&gt;
&lt;li&gt;Governance and RACI&lt;/li&gt;
&lt;li&gt;Data Model and Dictionary (Excerpt)&lt;/li&gt;
&lt;li&gt;Process Flows and SLAs&lt;/li&gt;
&lt;li&gt;Traceability Map&lt;/li&gt;
&lt;li&gt;Legal Reconciliation Matrix&lt;/li&gt;
&lt;li&gt;Proposed Amendments to SB 1330&lt;/li&gt;
&lt;li&gt;KPIs (Key Performance Indicators)&lt;/li&gt;
&lt;li&gt;Risk Register (Top Risks and Controls)&lt;/li&gt;
&lt;li&gt;Procurement and Costing (RA 9184)&lt;/li&gt;
&lt;li&gt;Interoperability and Migration&lt;/li&gt;
&lt;li&gt;Accessibility and Inclusion&lt;/li&gt;
&lt;li&gt;Appendix: Examples&lt;/li&gt;
&lt;li&gt;Roadmap&lt;/li&gt;
&lt;li&gt;Security Considerations&lt;/li&gt;
&lt;li&gt;Data Sovereignty &amp;amp; Residency&lt;/li&gt;
&lt;li&gt;Legal Framework&lt;/li&gt;
&lt;li&gt;FAQ&lt;/li&gt;
&lt;li&gt;References&lt;/li&gt;
&lt;li&gt;Related Resources&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  📚 Glossary (Selected)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;TELS&lt;/strong&gt;: Tamper-Evident Ledger Systems (tech-neutral immutability layer).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hash&lt;/strong&gt;: Digital fingerprint of a file/record used to verify integrity.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Structured Data&lt;/strong&gt;: Tabular/JSON items (e.g., budget line items).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Unstructured Data&lt;/strong&gt;: Files such as PDFs, images (receipts, contracts).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;SLA&lt;/strong&gt;: Service Level Agreement (deadline/quality target for a process).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RACI&lt;/strong&gt;: Responsibility matrix (Responsible, Accountable, Consulted, Informed).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="key-statistics"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📊 Key Statistics
&lt;/h3&gt;

&lt;p&gt;&lt;a id="objectives-scope"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🎯 Objectives and Scope
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Objectives: Make every peso traceable end-to-end; enable real-time oversight; deter tampering through evidence; empower citizens with usable transparency&lt;/li&gt;
&lt;li&gt;Scope: DBM (appropriations/allotments), PhilGEPS (procurement), agencies (delivery/acceptance/accounting), BTr (cash release/disbursement), COA (real-time audit)&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Out of scope: Storing raw documents on-chain; blockchain-only mandates; public L1 dependence for storage&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Current Problem&lt;/strong&gt;: ₱50M+ plunder threshold leaves smaller fraud unchecked&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Proposed Penalties&lt;/strong&gt;: Reclusion perpetua for ₱1M+ fraud; scaled punishments with asset forfeiture and perpetual disqualification (RA 9346-compliant)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Whistleblower Rewards&lt;/strong&gt;: Up to ₱500M (5% of recovered funds)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Pilot Duration&lt;/strong&gt;: 2 years in DBM, DPWH, and 3 LGUs&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Technology Scope&lt;/strong&gt;: Blockchain, DLT, DAG, ZKPs, and other immutable systems&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Cost Reduction&lt;/strong&gt;: 90% storage savings, 100% gas fee elimination&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Data Privacy&lt;/strong&gt;: Full RA 10173 compliance with correction rights&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="critical-design-principles"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  ⚠️ Critical Design Principles
&lt;/h3&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Blockchain = Proof, Not Storage&lt;/strong&gt; 🎯
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Misconception that blockchain should store everything&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Reality&lt;/strong&gt;: Blockchain is a fingerprint system, not a filing cabinet&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Hybrid architecture - databases for data, blockchain for verification&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cost Impact&lt;/strong&gt;: Prevents ₱60M+ storage costs and gas fees&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Compliance&lt;/strong&gt;: Avoids Data Privacy Act conflicts&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Structured vs Unstructured Data Architecture&lt;/strong&gt; 📊
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Structured Data&lt;/strong&gt; (Budget items, allocations): JSON/CSV in databases&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Unstructured Data&lt;/strong&gt; (Receipts, contracts, documents): File repositories&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Verification Layer&lt;/strong&gt;: Only hashes stored on blockchain&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Processing&lt;/strong&gt;: Validation pipelines before blockchain commitment&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Cost-Benefit Analysis&lt;/strong&gt; 💰
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Current Problem&lt;/strong&gt;: ₱60M+ projects with unclear ROI&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Proposed Solution&lt;/strong&gt;: Pilot-first approach with measurable outcomes&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gas Fee Mitigation&lt;/strong&gt;: Local blockchain nodes, not foreign hosting&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Storage Costs&lt;/strong&gt;: 99% reduction through hash-only approach&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="core-framework-components"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🔧 Core Framework Components
&lt;/h3&gt;

&lt;h4&gt;
  
  
  1. &lt;strong&gt;Severe Penalties for Fraud&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Budget tampering treated as ordinary falsification&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Scaled penalties compliant with RA 9346 (no death penalty): e.g., ₱1M+ → reclusion perpetua, perpetual disqualification, asset forfeiture; ₱500k–₱999,999 → reclusion temporal; ₱100k–₱499,999 → prisión mayor; with proportional fines.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RPC Arts. 171–172; RA 7080; RA 9346 (prohibits death penalty)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  2. &lt;strong&gt;Collusion Prevention&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Validators may conspire to approve fake entries&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Immutable logging + Reclusion Perpetua + ₱5B fine&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RPC Art. 217 (Malversation)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  3. &lt;strong&gt;Immutable Amendment Logging&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: "Midnight insertions" lack traceability&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Mandatory logging of proponent, signature, timestamp, justification&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 8792 (E-Commerce Act)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  4. &lt;strong&gt;Real-Time COA Oversight&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Delayed audits arrive after corruption is entrenched&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Direct TELS access + quarterly independent audits&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: Constitution, Art. IX-D&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  5. &lt;strong&gt;Transparency Enforcement&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Officials delay/block budget data release&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Non-compliance auto-flagged + Reclusion Temporal&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: PD 1445 (Government Auditing Code)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  6. &lt;strong&gt;Whistleblower Protection &amp;amp; Rewards&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Insiders fear retaliation, no financial incentive&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: 5% reward (max ₱500M) + Witness Protection Program&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 6981&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  7. &lt;strong&gt;Citizen-Friendly Transparency&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Data hidden in PDFs, technical jargon&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Mobile dashboards, plain language, multilingual support; proactive disclosure aligned with FOI and RA 11032 (Ease of Doing Business)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 9485 (Anti-Red Tape Act), RA 11032, EO No. 2 (2016) FOI&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  8. &lt;strong&gt;Independent Oversight Committee&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Single-body monopoly over monitoring&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Multi-sector committee (COA, Congress, academe, civil society)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 3019 (Anti-Graft)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  9. &lt;strong&gt;Phased Rollout Strategy&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Big-bang IT projects often fail&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: 2-year pilot in DBM, DPWH, 3 LGUs before national rollout&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: PD 1445&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  10. &lt;strong&gt;Cybersecurity &amp;amp; Resilience&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Systems vulnerable to hacking and sabotage&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Ledger Security Operations Center (SOC) + penetration testing&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 10175 (Cybercrime Prevention Act)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  11. &lt;strong&gt;Technology-Neutral Systems&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Bill prescribes blockchain only&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: TELS framework supporting blockchain, DLT, DAG, ZKPs, timestamping&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: BusinessMirror critique (Ann Cuisia, Sept 2025)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  12. &lt;strong&gt;Data Engineering Standards&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Unstructured, inconsistent budget data&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Unified schema, validation pipelines, structured/unstructured separation&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 8792, PD 1445&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  13. &lt;strong&gt;Blockchain as Proof, Not Storage&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Misconception that blockchain should store everything&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Hybrid model - hashes on-chain, full data in databases&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 10173 (Data Privacy Act), RA 8792&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  14. &lt;strong&gt;Data Privacy Act Compliance &amp;amp; Right to Correction&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: Immutable blockchain conflicts with citizen's right to correct/delete data&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Correction requests logged on-chain, original data updated in databases&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Process&lt;/strong&gt;: Citizen requests → Validation → Database update → New hash on-chain&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 10173 (Data Privacy Act)&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  15. &lt;strong&gt;Cost-Effective Implementation Strategy&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem&lt;/strong&gt;: ₱60M+ projects with unclear ROI and foreign gas fees&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Solution&lt;/strong&gt;: Local blockchain nodes, hash-only storage, pilot validation&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cost Breakdown&lt;/strong&gt;: 90% reduction in storage costs, 100% elimination of foreign gas fees&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Basis&lt;/strong&gt;: RA 9184 (Government Procurement Reform Act)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="technical-architecture"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🏗️ Technical Architecture (Hybrid Model)
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;┌─────────────────────────────────────────────────────────────────┐
│                    DATA LAYER (Databases)                      │
│  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐            │
│  │ Structured  │  │Unstructured │  │   Metadata  │            │
│  │   Data      │  │    Data     │  │   &amp;amp; Logs    │            │
│  │ (JSON/CSV)  │  │(Files/PDFs) │  │ (Timestamps)│            │
│  └─────────────┘  └─────────────┘  └─────────────┘            │
└─────────────────────────────────────────────────────────────────┘
                                │
                                ▼
┌─────────────────────────────────────────────────────────────────┐
│                VERIFICATION LAYER (TELS)                       │
│  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐            │
│  │   Hash      │  │  Digital    │  │ Validation  │            │
│  │ Storage     │  │ Signatures  │  │  Rules      │            │
│  │(Blockchain) │  │(Immutable)  │  │(Smart Cont.)│            │
│  └─────────────┘  └─────────────┘  └─────────────┘            │
└─────────────────────────────────────────────────────────────────┘
                                │
                                ▼
┌─────────────────────────────────────────────────────────────────┐
│                 TRANSPARENCY LAYER (APIs)                      │
│  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐            │
│  │  Citizen    │  │   COA       │  │   Media     │            │
│  │ Dashboard   │  │  Real-time  │  │   Tools     │            │
│  │(Mobile/Web) │  │ Monitoring  │  │(Analytics)  │            │
│  └─────────────┘  └─────────────┘  └─────────────┘            │
└─────────────────────────────────────────────────────────────────┘
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a id="cost-benefit-analysis"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  💰 Cost-Benefit Analysis
&lt;/h3&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Current Problem (Traditional Approach)&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Storage Costs&lt;/strong&gt;: ₱60M+ for full data on blockchain&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gas Fees&lt;/strong&gt;: ₱500k-₱2M monthly for foreign hosting&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Performance&lt;/strong&gt;: Slow transactions, high latency&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Risk&lt;/strong&gt;: Data Privacy Act violations&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Proposed Solution (Hybrid Model)&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Storage Costs&lt;/strong&gt;: ₱6M (90% reduction) - databases only&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gas Fees&lt;/strong&gt;: ₱0 (local nodes, hash-only transactions)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Performance&lt;/strong&gt;: Fast queries, real-time updates&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Legal Compliance&lt;/strong&gt;: Full Data Privacy Act compliance&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;ROI Calculation&lt;/strong&gt;
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Initial Investment&lt;/strong&gt;: ₱15M (pilot phase)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Annual Savings&lt;/strong&gt;: ₱25M (vs traditional blockchain)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Break-even&lt;/strong&gt;: 7 months&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;5-year ROI&lt;/strong&gt;: 800%&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Assumptions and Sources (for estimation)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Let &lt;code&gt;N_tx&lt;/code&gt; = number of budget events to anchor per year (e.g., line-item approvals, amendments, disbursements). Provide from DBM operations data.&lt;/li&gt;
&lt;li&gt;Let &lt;code&gt;S_doc_avg&lt;/code&gt; = average size of supporting documents per event (GB). Use your agency’s measured average; avoid guessing.&lt;/li&gt;
&lt;li&gt;Object storage price &lt;code&gt;p_store&lt;/code&gt; ≈ USD 0.023/GB-month (public benchmark, AWS S3 Standard) for estimation only: &lt;a href="https://aws.amazon.com/s3/pricing/" rel="noopener noreferrer"&gt;https://aws.amazon.com/s3/pricing/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;If using public L1 storage/transactions: on Ethereum, calldata non‑zero bytes cost 16 gas/byte (EIP‑2028): &lt;a href="https://eips.ethereum.org/EIPS/eip-2028" rel="noopener noreferrer"&gt;https://eips.ethereum.org/EIPS/eip-2028&lt;/a&gt;; gas price varies (see Etherscan Gas Tracker): &lt;a href="https://etherscan.io/gastracker" rel="noopener noreferrer"&gt;https://etherscan.io/gastracker&lt;/a&gt;. We avoid this by running permissioned, local nodes.&lt;/li&gt;
&lt;li&gt;Local validator node cost: let &lt;code&gt;c_node_month&lt;/code&gt; come from GOVCloud/DICT or IaaS quote (e.g., comparable to 2 vCPU/8GB VM reference price; see EC2 on‑demand reference: &lt;a href="https://aws.amazon.com/ec2/pricing/" rel="noopener noreferrer"&gt;https://aws.amazon.com/ec2/pricing/&lt;/a&gt;). Use actual DICT/GovCloud prices in procurement.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Formulas
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Annual object storage (documents) cost: &lt;code&gt;Cost_docs_year = (Total_Doc_GB_month_average × 12) × p_store&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;If storing raw docs on public chain (not recommended):

&lt;ul&gt;
&lt;li&gt;Per‑event gas: &lt;code&gt;Gas_event ≈ 16 × bytes_calldata + base_gas_tx&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Annual gas USD: &lt;code&gt;Cost_gas_year = N_tx × Gas_event × gas_price_gwei × 1e-9 × ETHUSD&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;Permissioned hash‑only anchoring cost: negligible gas; infra cost dominates.

&lt;ul&gt;
&lt;li&gt;Infra annual cost: &lt;code&gt;Cost_infra_year = N_nodes × c_node_month × 12&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;Hybrid total annual: &lt;code&gt;Cost_hybrid_year = Cost_docs_year + Cost_infra_year&lt;/code&gt;
&lt;/li&gt;

&lt;/ul&gt;

&lt;h4&gt;
  
  
  Example computation (replace with your real inputs)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Inputs (example):

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;N_tx&lt;/code&gt; = 1,000,000 events/year&lt;/li&gt;
&lt;li&gt;Average attached documents 2 MB/event ⇒ &lt;code&gt;Total_Doc_GB_month_average ≈ (1,000,000 × 2 MB) / (1024 MB/GB) / 12 ≈ 162.8 GB/month&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;p_store&lt;/code&gt; = USD 0.023/GB‑month (reference)&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;N_nodes&lt;/code&gt; = 5 permissioned validators; &lt;code&gt;c_node_month&lt;/code&gt; = USD 60/month (reference VM; replace with DICT/GovCloud quote)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;Calculations:

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Cost_docs_year = 162.8 × 12 × 0.023 ≈ USD 44.9/year&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;Cost_infra_year = 5 × 60 × 12 = USD 3,600/year&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;Cost_hybrid_year ≈ USD 3,645/year&lt;/code&gt; (documents in object storage; hashes on chain; local nodes)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;For comparison only (do NOT implement): storing 2 MB/event as calldata on a public chain with &lt;code&gt;bytes_calldata ≈ 2,000,000&lt;/code&gt;, &lt;code&gt;base_gas_tx ≈ 21,000&lt;/code&gt;, &lt;code&gt;gas_price = 20 gwei&lt;/code&gt;, &lt;code&gt;ETHUSD = 3,000&lt;/code&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Gas_event ≈ (16 × 2,000,000) + 21,000 = 32,021,000 gas&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;Cost_event_USD ≈ 32,021,000 × 20e-9 × 3,000 ≈ USD 1,921.26&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;Annual_gas ≈ 1,000,000 × 1,921.26 = USD 1.92B&lt;/code&gt; (illustrates why “blockchain = storage” is economically infeasible)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These examples use public reference prices (cited) and standard gas formulas (EIP‑2028). Replace all placeholders with official DICT/GovCloud price quotes and DBM volumes during procurement.&lt;/p&gt;

&lt;p&gt;&lt;a id="governance-and-raci"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🧑‍⚖️ Governance and RACI (Summary)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;DBM (Owner)&lt;/strong&gt;: Operates data pipelines; enforces submission SLAs; publishes datasets and metadata.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;COA (Oversight)&lt;/strong&gt;: Real-time audit access; runs anomaly analytics; issues audit observations.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DICT (Platform/SOC)&lt;/strong&gt;: Runs infrastructure, validator nodes, HSM/key management, incident response.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Oversight Committee&lt;/strong&gt;: Multi-sector (COA, Congress, academe, civil society, private sector) issuing quarterly public reports in TELS.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RACI per Process&lt;/strong&gt;: Submission (Agency R/DBM A); Validation (DBM R/DICT C/COA I); Commit (DICT R, DBM A); Correction (DBM R, COA C, Citizen I); Non-compliance (DBM A, COA I, Oversight I).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="data-model"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🗃️ Data Model and Dictionary (Excerpt)
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Structured Budget Item (minimum fields)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;agencyId&lt;/code&gt;, &lt;code&gt;programCode&lt;/code&gt;, &lt;code&gt;lineItemId&lt;/code&gt;, &lt;code&gt;uacsCode&lt;/code&gt;, &lt;code&gt;fundSource&lt;/code&gt;, &lt;code&gt;amount&lt;/code&gt;, &lt;code&gt;locationCode&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;proponentId&lt;/code&gt;, &lt;code&gt;approverId&lt;/code&gt;, &lt;code&gt;validatorIds[]&lt;/code&gt;, &lt;code&gt;justificationText&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;createdAt&lt;/code&gt;, &lt;code&gt;approvedAt&lt;/code&gt;, &lt;code&gt;amendedAt&lt;/code&gt;, &lt;code&gt;attachmentHashes[]&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Unstructured Document Metadata
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;documentType&lt;/code&gt; (receipt, contract, payroll, invoice), &lt;code&gt;issuer&lt;/code&gt;, &lt;code&gt;dateIssued&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;fileChecksum&lt;/code&gt; (SHA-256), &lt;code&gt;storageUri&lt;/code&gt;, &lt;code&gt;retentionPolicy&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Classification Levels
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Public, Restricted (personal), Confidential (security), Secret (if applicable)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Validation pipelines shall reject records missing required fields or failing schema/consistency checks.&lt;/p&gt;

&lt;h4&gt;
  
  
  Procurement (OCDS-aligned) Core Entities
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;Planning&lt;/code&gt; (budget and procurement plan linkage): &lt;code&gt;ocid&lt;/code&gt;, &lt;code&gt;buyer.id&lt;/code&gt;, &lt;code&gt;budget.breakdownID&lt;/code&gt;, &lt;code&gt;telsTraceId&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;Tender&lt;/code&gt; (notice): &lt;code&gt;ocid&lt;/code&gt;, &lt;code&gt;id&lt;/code&gt;, &lt;code&gt;title&lt;/code&gt;, &lt;code&gt;status&lt;/code&gt;, &lt;code&gt;tenderPeriod&lt;/code&gt;, &lt;code&gt;items[]&lt;/code&gt;, &lt;code&gt;value.amount&lt;/code&gt;, &lt;code&gt;procurementMethod&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;Award&lt;/code&gt;: &lt;code&gt;ocid&lt;/code&gt;, &lt;code&gt;id&lt;/code&gt;, &lt;code&gt;suppliers[]&lt;/code&gt;, &lt;code&gt;value.amount&lt;/code&gt;, &lt;code&gt;date&lt;/code&gt;, &lt;code&gt;documents[].hash&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;Contract&lt;/code&gt;: &lt;code&gt;ocid&lt;/code&gt;, &lt;code&gt;id&lt;/code&gt;, &lt;code&gt;awardID&lt;/code&gt;, &lt;code&gt;dateSigned&lt;/code&gt;, &lt;code&gt;value.amount&lt;/code&gt;, &lt;code&gt;implementation.milestones[]&lt;/code&gt;, &lt;code&gt;documents[].hash&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;References: Open Contracting Data Standard (OCDS) schema: &lt;a href="https://standard.open-contracting.org/latest/en/" rel="noopener noreferrer"&gt;https://standard.open-contracting.org/latest/en/&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Disbursement and Treasury Linkages
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;ObligationRequest (OBR)&lt;/code&gt;: &lt;code&gt;obrId&lt;/code&gt;, &lt;code&gt;agencyId&lt;/code&gt;, &lt;code&gt;uacsCode&lt;/code&gt;, &lt;code&gt;amount&lt;/code&gt;, &lt;code&gt;fundSource&lt;/code&gt;, &lt;code&gt;telsTraceId&lt;/code&gt;, &lt;code&gt;digitalSignatures[]&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;DisbursementVoucher (DV)&lt;/code&gt;: &lt;code&gt;dvId&lt;/code&gt;, &lt;code&gt;supplierId&lt;/code&gt;, &lt;code&gt;contractId&lt;/code&gt;, &lt;code&gt;amountGross&lt;/code&gt;, &lt;code&gt;taxes&lt;/code&gt;, &lt;code&gt;amountNet&lt;/code&gt;, &lt;code&gt;telsTraceId&lt;/code&gt;, &lt;code&gt;attachmentHashes[]&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;CashRelease (BTr)&lt;/code&gt;: &lt;code&gt;ncaId&lt;/code&gt;, &lt;code&gt;dvId&lt;/code&gt;, &lt;code&gt;amount&lt;/code&gt;, &lt;code&gt;releaseDate&lt;/code&gt;, &lt;code&gt;bankRef&lt;/code&gt;, &lt;code&gt;telsTraceId&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All financial postings reference UACS codes and carry &lt;code&gt;telsTraceId&lt;/code&gt; for cross-system correlation.&lt;/p&gt;

&lt;p&gt;&lt;a id="process-flows-slas"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🔄 Process Flows and SLAs
&lt;/h3&gt;

&lt;p&gt;1) Submission&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Agency encodes records → Schema validation (≤ 2 hours) → Queue for validation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;2) Validation&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Automated checks (UACS totals, duplicates, range checks) + role-based approvals (≤ 2 days)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;3) Commit&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Write to databases → Generate hash → Anchor hash on TELS (≤ 1 hour)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;4) Correction (Data Privacy Act)&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Request intake (portal) → Identity verification → Review (≤ 10 days)&lt;/li&gt;
&lt;li&gt;Database update → New hash on TELS → Immutable audit trail preserved&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;5) Non-compliance&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Auto-flag missed deadlines → Notify COA and Oversight Committee&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Signatories and Digital Signatures (PNPKI)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Each critical event is signed by role holders using PNPKI-qualified certificates:

&lt;ul&gt;
&lt;li&gt;Agency Budget Officer (submission)&lt;/li&gt;
&lt;li&gt;BAC Chair/Secretariat (tender/bid events)&lt;/li&gt;
&lt;li&gt;HOPE (award/contract approval)&lt;/li&gt;
&lt;li&gt;Inspection/Acceptance Committee (IAR)&lt;/li&gt;
&lt;li&gt;Accounting Officer (OBR/DV)&lt;/li&gt;
&lt;li&gt;Agency Head/Authorized Signatory (DV approval)&lt;/li&gt;
&lt;li&gt;BTr Authorized Officer (cash release)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;
&lt;code&gt;digitalSignatures[]&lt;/code&gt; contains signer &lt;code&gt;commonName&lt;/code&gt;, &lt;code&gt;issuer&lt;/code&gt;, &lt;code&gt;serialNumber&lt;/code&gt;, &lt;code&gt;signatureAlgorithm&lt;/code&gt;, &lt;code&gt;signature&lt;/code&gt;, and &lt;code&gt;signedAt&lt;/code&gt;.&lt;/li&gt;

&lt;li&gt;Signature hashes and certificate chains are anchored in TELS for verification.&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;a id="traceability-map"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🔗 Traceability Map (Keys and Joins)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;telsTraceId&lt;/code&gt;: Shared across all stages to link records end-to-end&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;ocid&lt;/code&gt;: Links PhilGEPS Planning/Tender/Award/Contract artifacts&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;uacsCode&lt;/code&gt;: Standard accounting codes for classification and checks&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;contractId&lt;/code&gt; ↔ &lt;code&gt;dvId&lt;/code&gt;/&lt;code&gt;obrId&lt;/code&gt;: Connects contract obligations to disbursements&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;ncaId&lt;/code&gt; ↔ &lt;code&gt;dvId&lt;/code&gt;: Connects cash allocations to payments&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;documents[].hash&lt;/code&gt; and &lt;code&gt;attachmentHashes[]&lt;/code&gt;: Verify documents consistently across systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="legal-matrix"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  ⚖️ Legal Reconciliation Matrix (Highlights)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;RA 10173 (Data Privacy Act) right to rectification vs immutability

&lt;ul&gt;
&lt;li&gt;Store mutable data in database; record correction events on TELS; keep verifiable history&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;PD 1445 (Auditing) timely submissions

&lt;ul&gt;
&lt;li&gt;Auto-flags for missing/late entries; penalties for obstruction; COA alerting&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;RA 9346 (No Death Penalty)

&lt;ul&gt;
&lt;li&gt;Penalty scaling uses reclusion and asset forfeiture, not capital punishment&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;RA 8792 (E-Commerce) electronic signatures

&lt;ul&gt;
&lt;li&gt;Require digital signatures on amendments; signature evidence logged in TELS&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;a id="kpis"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📊 KPIs (Key Performance Indicators)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Transparency Coverage: % of budget lines with publicly verifiable hashes (TELS events)&lt;/li&gt;
&lt;li&gt;Timeliness: Median time from submission → commit (process logs)&lt;/li&gt;
&lt;li&gt;Correction SLA: % of requests completed within 15 days (correction module)&lt;/li&gt;
&lt;li&gt;Audit Lead Time: Days from spend to COA visibility (access logs)&lt;/li&gt;
&lt;li&gt;Data Quality: % of records passing validation on first submission&lt;/li&gt;
&lt;li&gt;Public Engagement: Dashboard users, API calls, FOI-linked queries&lt;/li&gt;
&lt;li&gt;Deterrence: Year-over-year reduction in anomalies flagged&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="risk-register"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  ☂️ Risk Register (Top Risks &amp;amp; Controls)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Legal challenge on penalties → Align with jurisprudence; DOJ/OGCC review&lt;/li&gt;
&lt;li&gt;Adoption resistance → Training, change champions, executive directives&lt;/li&gt;
&lt;li&gt;Data quality issues → Mandatory schema validation; agency scorecards; escalation&lt;/li&gt;
&lt;li&gt;Vendor lock-in → Tech-neutral specs; open standards; modular procurement lots&lt;/li&gt;
&lt;li&gt;Security breach → HSM key custody; node quorum/BFT; red teaming; DR drills&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="procurement"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🧾 Procurement and Costing (RA 9184)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Lots: Core platform, SOC services, integration adapters, citizen dashboard, training&lt;/li&gt;
&lt;li&gt;Evaluation: QCBE with technical scoring; open standards compliance mandatory&lt;/li&gt;
&lt;li&gt;Milestones/Payments: Pilot deploy → COA integration → Dashboard live → Independent audit pass&lt;/li&gt;
&lt;li&gt;Licensing: Prefer permissive/open-source; publish non-sensitive components&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="interoperability"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🔌 Interoperability and Migration
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Integrations: DBM budget systems (eBudget, BTMS), COA eNGAS/eBudget, PhilGEPS, Bureau of the Treasury (BTr) Cash Management&lt;/li&gt;
&lt;li&gt;Canonical schema adapters; API gateways; event streaming for updates&lt;/li&gt;
&lt;li&gt;Migration: Prioritize current fiscal year; backfill prior 3 years’ hashes progressively&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Agency Integration Flows (high level)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;DBM → Appropriations, allotments, SARO/NCAs; publishes structured records; TELS anchors hashes and metadata&lt;/li&gt;
&lt;li&gt;PhilGEPS → Procurement notices, bids, awards, contracts (OCDS-aligned); TELS anchors award and contract hashes&lt;/li&gt;
&lt;li&gt;Procuring Entity (Agency) → Delivery/inspection/acceptance (IAR), billing, DV/OBR; TELS anchors receiving and acceptance events&lt;/li&gt;
&lt;li&gt;BTr → Cash releases and disbursement confirmations; TELS anchors payment proofs and references to NCA/SAA&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All inter-agency events share a common Trace ID to enable end-to-end linkage (Appropriation → Allotment → Procurement → Contract → Delivery → Billing → Disbursement).&lt;/p&gt;

&lt;p&gt;&lt;a id="agency-integrations"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🏛️ Agency Integrations &amp;amp; Standards
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;DBM&lt;/strong&gt;: Appropriations, Allotments (SARO), Notices of Cash Allocation (NCA); UACS-coded; publishes structured records; hashes anchored in TELS&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;PhilGEPS&lt;/strong&gt;: OCDS-aligned procurement data: Planning, Tender, Award, Contract; publish documents with hashes; expose APIs for TELS anchoring&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Agencies (PEs)&lt;/strong&gt;: Delivery, Inspection &amp;amp; Acceptance (IAR), Billing Statements, OBR/DV with attachments; sign via PNPKI; anchor events in TELS&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;BTr&lt;/strong&gt;: Cash releases and disbursement confirmations; references DV/NCA; anchor proof records and bank refs in TELS&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;COA&lt;/strong&gt;: Real-time audit access; anomaly analytics; quarterly public reporting via Oversight Committee&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Standards: UACS (DBM-COA-DOF JC 2013-1), OCDS (Open Contracting), PNPKI (DICT), FOI/RA 11032 compliance, Data Privacy (RA 10173).&lt;/p&gt;

&lt;p&gt;&lt;a id="accessibility"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🌍 Accessibility and Inclusion
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;WCAG 2.1 AA; simple Filipino/English + regional languages&lt;/li&gt;
&lt;li&gt;Mobile-first; low-bandwidth mode; printable summaries&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="appendix-examples"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📎 Appendix: Examples
&lt;/h3&gt;

&lt;h4&gt;
  
  
  A. Sample JSON Schema: &lt;code&gt;BudgetItem&lt;/code&gt;
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"$schema"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"http://json-schema.org/draft-07/schema#"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"title"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"BudgetItem"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"object"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"required"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"agencyId"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"programCode"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"lineItemId"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"uacsCode"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"amount"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"fundSource"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"proponentId"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"approverId"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"createdAt"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"properties"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"agencyId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"programCode"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"lineItemId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"uacsCode"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"amount"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"number"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"minimum"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"fundSource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"locationCode"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"proponentId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"approverId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"validatorIds"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"array"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"justificationText"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"attachmentHashes"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"array"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"createdAt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"date-time"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"approvedAt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"date-time"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"amendedAt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"string"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"date-time"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  B. Correction Request Flow (DPA-Compliant)
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"requestId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"REQ-2025-0001"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"requestor"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"fullName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Juan Dela Cruz"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"CIT-12345"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"recordRef"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"BudgetItem"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"lineItemId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"LI-2025-0456"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"claimedError"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Incorrect amount encoding"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"proposedFix"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"amount"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1250000&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"submittedAt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2025-10-03T09:00:00Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"status"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"UNDER_REVIEW"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"slaDays"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  C. Verify File Hash API (Proof, not Storage)
&lt;/h4&gt;

&lt;p&gt;Request&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="err"&gt;GET /api/v1/verify?lineItemId=LI-2025-0456&amp;amp;docHash=0xabc123...
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Response&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"lineItemId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"LI-2025-0456"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"docHash"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"0xabc123..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"anchored"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"blockHeight"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;128945&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"anchoredAt"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2025-10-03T10:05:00Z"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"signers"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"DICT-VALIDATOR-01"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"COA-NODE-02"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"verdict"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"MATCHES_ON_CHAIN"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a id="proposed-amendments"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🧩 Proposed Amendments to SB 1330 (Technology-Neutral TELS)
&lt;/h3&gt;

&lt;p&gt;1) Title and Definitions&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Replace references to “blockchain” with “Tamper-Evident Ledger Systems (TELS)” defined as technology-neutral systems providing cryptographic immutability and public verifiability, including but not limited to DLT, blockchain, DAGs, append-only cryptographic logs, secure timestamping, and zero-knowledge systems.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;2) Storage vs Proof&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Clarify that full records remain in government databases or repositories; only digital fingerprints (hashes), timestamps, signatures, and minimal metadata shall be recorded on TELS for verification.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;3) Mandatory Amendment Logging&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Require that every insertion, realignment, or change include the proponent’s name/office, justification, timestamp, digital signature, and validator/approver identity; all actions recorded in TELS.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;4) COA Real-Time Access&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Mandate COA real-time read access to TELS and associated APIs; allow COA-accredited independent audits at least quarterly.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;5) Transparency and FOI Compliance&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Require citizen-friendly dashboards, open APIs, multilingual support, and proactive disclosure aligned with EO No. 2 (2016) FOI and RA 11032.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;6) Data Privacy and Corrections&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Establish a correction process compliant with RA 10173: corrections occur in databases; corresponding correction events (new hashes) logged to TELS, preserving an immutable trail.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;7) Penalties (RA 9346-Compliant)&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Scale penalties without capital punishment: ₱1M+ → reclusion perpetua + perpetual disqualification + asset forfeiture; ₱500k–₱999,999 → reclusion temporal; ₱100k–₱499,999 → prisión mayor; with proportional fines and administrative sanctions for obstruction/non-submission.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;8) Cybersecurity &amp;amp; Node Governance&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Direct DICT to operate a Ledger SOC; require at least five validator nodes (DICT, COA, DBM, academe, independent auditor) with BFT quorum; mandate HSM-backed key management and regular penetration testing.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;9) Phased Rollout and Evaluation&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Implement a two-year pilot (DBM, DPWH, at least 3 LGUs); proceed to national rollout only after an independent evaluation confirms success against KPIs.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;10) Procurement and Tech Neutrality&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Procure via RA 9184 using tech-neutral specifications, open standards, modular lots, and milestone-based payments; prefer permissive/open-source components where feasible.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;11) Cost Controls and Data Residency&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Prioritize local nodes; prohibit mandatory use of foreign chains incurring gas fees; require cost/benefit disclosure; comply with DICT Cloud First and data residency guidance.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;12) Citizen Participation and Whistleblowers&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Provide whistleblower rewards up to 5% of recovered funds (cap), WPP protection per RA 6981; enable citizen reporting channels linked to TELS events.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Note: Drafting style and section numbering should align with the enrolled version of SB 1330 under consideration.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;WCAG 2.1 AA; simple Filipino/English + regional languages&lt;/li&gt;
&lt;li&gt;Mobile-first; low-bandwidth mode; printable summaries&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="implementation-roadmap"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🚀 Implementation Roadmap
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Phase 1: Foundation (Months 1-6)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;[ ] Legal framework finalization&lt;/li&gt;
&lt;li&gt;[ ] Technology selection and procurement&lt;/li&gt;
&lt;li&gt;[ ] Pilot agency selection (DBM, DPWH, 3 LGUs)&lt;/li&gt;
&lt;li&gt;[ ] Security architecture design&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Phase 2: Pilot Implementation (Months 7-30)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;[ ] TELS deployment in pilot agencies&lt;/li&gt;
&lt;li&gt;[ ] Data migration and standardization&lt;/li&gt;
&lt;li&gt;[ ] COA integration and real-time monitoring&lt;/li&gt;
&lt;li&gt;[ ] Citizen dashboard development&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Phase 3: Evaluation &amp;amp; Scaling (Months 31-36)
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;[ ] Independent pilot evaluation&lt;/li&gt;
&lt;li&gt;[ ] Performance metrics analysis&lt;/li&gt;
&lt;li&gt;[ ] National rollout planning&lt;/li&gt;
&lt;li&gt;[ ] Full-scale deployment&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="key-features"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🔍 Key Features
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Immutable Logging&lt;/strong&gt;: Every budget change permanently recorded&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Real-Time Monitoring&lt;/strong&gt;: COA and public oversight in real-time&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Scalable Penalties&lt;/strong&gt;: Punishment proportional to fraud amount&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Whistleblower Protection&lt;/strong&gt;: Financial incentives and legal protection&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Technology Neutral&lt;/strong&gt;: Not locked into specific blockchain technology&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Citizen Access&lt;/strong&gt;: User-friendly interfaces for public engagement&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Multi-Sector Oversight&lt;/strong&gt;: Prevents elite capture of monitoring systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="expected-outcomes"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📈 Expected Outcomes
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Transparency&lt;/strong&gt;: 100% of budget changes publicly traceable&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Accountability&lt;/strong&gt;: Clear ownership of every peso spent&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Deterrence&lt;/strong&gt;: Severe penalties make corruption financially suicidal&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Engagement&lt;/strong&gt;: Citizens actively monitor budget through accessible tools&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Efficiency&lt;/strong&gt;: Real-time oversight prevents corruption before it spreads&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Trust&lt;/strong&gt;: Restored public confidence in government financial management&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a id="security-considerations"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🛡️ Security Considerations
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Ledger Security Operations Center (SOC)&lt;/strong&gt;: 24/7 monitoring&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Penetration Testing&lt;/strong&gt;: Regular security assessments&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Disaster Recovery&lt;/strong&gt;: Redundant systems and backup procedures&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Data Privacy Compliance&lt;/strong&gt;: Full adherence to RA 10173&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Multi-Factor Authentication&lt;/strong&gt;: Enhanced access controls&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="data-sovereignty"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🗺️ Data Sovereignty &amp;amp; Residency
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;National systems (budget, tax, treasury) must operate on infrastructure under Philippine jurisdiction and control&lt;/li&gt;
&lt;li&gt;Prohibit mandatory reliance on foreign-controlled public chains for core records; use permissioned, locally governed nodes&lt;/li&gt;
&lt;li&gt;Store full records in government-managed databases; anchor only hashes to a state-governed ledger&lt;/li&gt;
&lt;li&gt;Require data residency per DICT Cloud First and applicable regulations; document locations, custodians, and failover sites&lt;/li&gt;
&lt;li&gt;Disclose any third-party chain dependencies; provide exit/migration plans and on-prem verification mirrors&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;References: DICT Cloud First Policy (DC 2020-002): &lt;a href="https://dict.gov.ph/cloud-first-policy/" rel="noopener noreferrer"&gt;https://dict.gov.ph/cloud-first-policy/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a id="legal-framework"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📚 Legal Framework
&lt;/h3&gt;

&lt;p&gt;The framework is grounded in existing Philippine laws:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;RPC Arts. 171-172&lt;/strong&gt;: Falsification penalties&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RA 7080&lt;/strong&gt;: Plunder law&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RA 8792&lt;/strong&gt;: E-Commerce Act&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RA 10175&lt;/strong&gt;: Cybercrime Prevention Act&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RA 10173&lt;/strong&gt;: Data Privacy Act&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;PD 1445&lt;/strong&gt;: Government Auditing Code&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🤝 Contributing
&lt;/h3&gt;

&lt;p&gt;This framework is designed for public input and collaboration. Key stakeholders include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Government Agencies&lt;/strong&gt;: DBM, COA, DICT, Congress&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Civil Society&lt;/strong&gt;: Transparency advocates, watchdog groups&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Academia&lt;/strong&gt;: Research institutions, policy experts&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Private Sector&lt;/strong&gt;: Technology providers, auditors&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Citizens&lt;/strong&gt;: End users and beneficiaries&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="faq"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  ❓ Frequently Asked Questions (Addressing Key Concerns)
&lt;/h3&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q1: Why not just put everything on blockchain?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: Blockchain is a fingerprint system, not a filing cabinet. Storing all data on-chain would:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cost ₱60M+ in storage fees&lt;/li&gt;
&lt;li&gt;Require ₱500k-₱2M monthly gas fees for foreign hosting&lt;/li&gt;
&lt;li&gt;Violate Data Privacy Act (right to correction/deletion)&lt;/li&gt;
&lt;li&gt;Make the system slow and expensive&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q2: How do we handle data correction requests under Data Privacy Act?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: Hybrid model allows corrections:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Citizen requests correction through official channels&lt;/li&gt;
&lt;li&gt;Request is validated and logged on blockchain&lt;/li&gt;
&lt;li&gt;Original data is updated in database&lt;/li&gt;
&lt;li&gt;New hash is generated and stored on blockchain&lt;/li&gt;
&lt;li&gt;Full audit trail maintained&lt;/li&gt;
&lt;/ol&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q3: What's the difference between structured and unstructured data?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Structured&lt;/strong&gt;: Budget items, allocations (JSON/CSV) → Fast queries, easy analysis&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Unstructured&lt;/strong&gt;: Receipts, contracts, documents (PDFs/images) → File storage, hash verification&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Processing&lt;/strong&gt;: Validation pipelines ensure data quality before blockchain commitment&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q4: How do we prevent the ₱60M+ project failure?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Start with ₱15M pilot (2 years)&lt;/li&gt;
&lt;li&gt;Measure concrete outcomes before scaling&lt;/li&gt;
&lt;li&gt;Local blockchain nodes (no foreign gas fees)&lt;/li&gt;
&lt;li&gt;Hash-only storage (90% cost reduction)&lt;/li&gt;
&lt;li&gt;Independent evaluation before national rollout&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q5: Who pays for gas fees and infrastructure?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Gas Fees&lt;/strong&gt;: ₱0 (local nodes, no foreign hosting)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Infrastructure&lt;/strong&gt;: Government-owned blockchain nodes&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Storage&lt;/strong&gt;: 90% reduction through hash-only approach&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Total Cost&lt;/strong&gt;: ₱6M vs ₱60M+ traditional approach&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q6: How do we ensure this isn't just another IT project?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Focus on accountability outcomes, not technology&lt;/li&gt;
&lt;li&gt;Real-time COA oversight and citizen monitoring&lt;/li&gt;
&lt;li&gt;Severe penalties make corruption financially suicidal&lt;/li&gt;
&lt;li&gt;Multi-sector oversight prevents elite capture&lt;/li&gt;
&lt;li&gt;Measurable anti-corruption metrics&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q7: What happens if the blockchain is hacked?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Ledger Security Operations Center (SOC) 24/7 monitoring&lt;/li&gt;
&lt;li&gt;Regular penetration testing and security audits&lt;/li&gt;
&lt;li&gt;Disaster recovery and backup systems&lt;/li&gt;
&lt;li&gt;Hash verification allows detection of any tampering&lt;/li&gt;
&lt;li&gt;Multiple validation layers prevent single points of failure&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Q8: How do citizens actually use this system?&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;A&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Mobile-first dashboards with plain language&lt;/li&gt;
&lt;li&gt;Visual analytics and graphs&lt;/li&gt;
&lt;li&gt;Multilingual support (Tagalog, Cebuano, Ilocano)&lt;/li&gt;
&lt;li&gt;Open APIs for journalists and civic tech&lt;/li&gt;
&lt;li&gt;Real-time alerts for budget changes&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a id="related-resources"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  🔗 Related Resources
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;SB 1330 context article: &lt;a href="https://edgedavao.net/latest-news/2025/09/blockchain-budget-bill-filed-in-the-senate-to-boost-transparency-fund-classrooms/" rel="noopener noreferrer"&gt;https://edgedavao.net/latest-news/2025/09/blockchain-budget-bill-filed-in-the-senate-to-boost-transparency-fund-classrooms/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Background explainer: &lt;a href="https://medium.com/thecapital/blockchain-the-budget-bill-sbn-1330-revolutionizing-fiscal-transparency-in-the-philippines-4968846ad713" rel="noopener noreferrer"&gt;https://medium.com/thecapital/blockchain-the-budget-bill-sbn-1330-revolutionizing-fiscal-transparency-in-the-philippines-4968846ad713&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Open Contracting Data Standard (OCDS): &lt;a href="https://standard.open-contracting.org/" rel="noopener noreferrer"&gt;https://standard.open-contracting.org/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;COA (Commission on Audit): &lt;a href="https://www.coa.gov.ph/" rel="noopener noreferrer"&gt;https://www.coa.gov.ph/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;PhilGEPS (Philippine Government Electronic Procurement System): &lt;a href="https://philgeps.gov.ph/" rel="noopener noreferrer"&gt;https://philgeps.gov.ph/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;DICT Cloud First Policy: &lt;a href="https://dict.gov.ph/cloud-first-policy/" rel="noopener noreferrer"&gt;https://dict.gov.ph/cloud-first-policy/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;PNPKI (eGovernment Public Key Infrastructure): &lt;a href="https://dict.gov.ph/programs/electronic-government/" rel="noopener noreferrer"&gt;https://dict.gov.ph/programs/electronic-government/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;UACS (DBM-COA-DOF Joint Circular No. 2013-1): &lt;a href="https://www.dbm.gov.ph/index.php/letters-and-circulars/other-releases/295-joint-circular-no-2013-1" rel="noopener noreferrer"&gt;https://www.dbm.gov.ph/index.php/letters-and-circulars/other-releases/295-joint-circular-no-2013-1&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;NISTIR 8202: Blockchain Technology Overview (NIST): &lt;a href="https://nvlpubs.nist.gov/nistpubs/ir/2018/NIST.IR.8202.pdf" rel="noopener noreferrer"&gt;https://nvlpubs.nist.gov/nistpubs/ir/2018/NIST.IR.8202.pdf&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;EIP-2028: Calldata Gas Cost Reduction: &lt;a href="https://eips.ethereum.org/EIPS/eip-2028" rel="noopener noreferrer"&gt;https://eips.ethereum.org/EIPS/eip-2028&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Etherscan Gas Tracker: &lt;a href="https://etherscan.io/gastracker" rel="noopener noreferrer"&gt;https://etherscan.io/gastracker&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;AWS S3 Pricing (object storage benchmark): &lt;a href="https://aws.amazon.com/s3/pricing/" rel="noopener noreferrer"&gt;https://aws.amazon.com/s3/pricing/&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;NISTIR 8202: Blockchain Technology Overview (NIST): &lt;a href="https://nvlpubs.nist.gov/nistpubs/ir/2018/NIST.IR.8202.pdf" rel="noopener noreferrer"&gt;https://nvlpubs.nist.gov/nistpubs/ir/2018/NIST.IR.8202.pdf&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Open Contracting Data Standard (OCDS) documentation: &lt;a href="https://standard.open-contracting.org/latest/en/" rel="noopener noreferrer"&gt;https://standard.open-contracting.org/latest/en/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Open Contracting: Evidence and Results (impact brief): &lt;a href="https://www.open-contracting.org/impact/" rel="noopener noreferrer"&gt;https://www.open-contracting.org/impact/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;EIP-2028: Calldata gas cost reduction (for cost comparisons): &lt;a href="https://eips.ethereum.org/EIPS/eip-2028" rel="noopener noreferrer"&gt;https://eips.ethereum.org/EIPS/eip-2028&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Etherscan Gas Tracker (reference gas prices): &lt;a href="https://etherscan.io/gastracker" rel="noopener noreferrer"&gt;https://etherscan.io/gastracker&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;AWS S3 pricing (object storage benchmark): &lt;a href="https://aws.amazon.com/s3/pricing/" rel="noopener noreferrer"&gt;https://aws.amazon.com/s3/pricing/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;DICT PNPKI/eGovernment PKI: &lt;a href="https://dict.gov.ph/programs/electronic-government/" rel="noopener noreferrer"&gt;https://dict.gov.ph/programs/electronic-government/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;PhilGEPS portal: &lt;a href="https://philgeps.gov.ph/" rel="noopener noreferrer"&gt;https://philgeps.gov.ph/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;COA publications and circulars: &lt;a href="https://www.coa.gov.ph/publications/" rel="noopener noreferrer"&gt;https://www.coa.gov.ph/publications/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;DBM Budget Documents: &lt;a href="https://www.dbm.gov.ph/index.php/budget-documents" rel="noopener noreferrer"&gt;https://www.dbm.gov.ph/index.php/budget-documents&lt;/a&gt;
&lt;a id="references"&gt;&lt;/a&gt;
### 📚 References (Authoritative Links)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;&lt;p&gt;1987 Constitution, Art. IX-D (Commission on Audit): &lt;a href="https://www.officialgazette.gov.ph/constitutions/1987-constitution/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.officialgazette.gov.ph/constitutions/1987-constitution/" rel="noopener noreferrer"&gt;https://www.officialgazette.gov.ph/constitutions/1987-constitution/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Presidential Decree No. 1445 (Government Auditing Code): &lt;a href="https://lawphil.net/statutes/presdecs/pd1978/pd_1445_1978.html" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://lawphil.net/statutes/presdecs/pd1978/pd_1445_1978.html" rel="noopener noreferrer"&gt;https://lawphil.net/statutes/presdecs/pd1978/pd_1445_1978.html&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Republic Act No. 10173 (Data Privacy Act): &lt;a href="https://www.privacy.gov.ph/data-privacy-act/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.privacy.gov.ph/data-privacy-act/" rel="noopener noreferrer"&gt;https://www.privacy.gov.ph/data-privacy-act/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Republic Act No. 8792 (E-Commerce Act): &lt;a href="https://lawphil.net/statutes/repacts/ra2000/ra_8792_2000.html" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://lawphil.net/statutes/repacts/ra2000/ra_8792_2000.html" rel="noopener noreferrer"&gt;https://lawphil.net/statutes/repacts/ra2000/ra_8792_2000.html&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Republic Act No. 9346 (Prohibiting Death Penalty): &lt;a href="https://lawphil.net/statutes/repacts/ra2006/ra_9346_2006.html" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://lawphil.net/statutes/repacts/ra2006/ra_9346_2006.html" rel="noopener noreferrer"&gt;https://lawphil.net/statutes/repacts/ra2006/ra_9346_2006.html&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Republic Act No. 9184 (Government Procurement Reform Act): &lt;a href="https://www.gppb.gov.ph/laws/laws/RA_9184.pdf" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.gppb.gov.ph/laws/laws/RA_9184.pdf" rel="noopener noreferrer"&gt;https://www.gppb.gov.ph/laws/laws/RA_9184.pdf&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Republic Act No. 3019 (Anti-Graft and Corrupt Practices Act): &lt;a href="https://www.officialgazette.gov.ph/1960/08/17/republic-act-no-3019/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.officialgazette.gov.ph/1960/08/17/republic-act-no-3019/" rel="noopener noreferrer"&gt;https://www.officialgazette.gov.ph/1960/08/17/republic-act-no-3019/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Republic Act No. 11032 (Ease of Doing Business): &lt;a href="https://www.officialgazette.gov.ph/2018/05/28/republic-act-no-11032/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.officialgazette.gov.ph/2018/05/28/republic-act-no-11032/" rel="noopener noreferrer"&gt;https://www.officialgazette.gov.ph/2018/05/28/republic-act-no-11032/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Executive Order No. 2, s. 2016 (Freedom of Information): &lt;a href="https://www.officialgazette.gov.ph/2016/07/23/executive-order-no-2-s-2016/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.officialgazette.gov.ph/2016/07/23/executive-order-no-2-s-2016/" rel="noopener noreferrer"&gt;https://www.officialgazette.gov.ph/2016/07/23/executive-order-no-2-s-2016/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;DICT Cloud First Policy (DC 2020-002): &lt;a href="https://dict.gov.ph/cloud-first-policy/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://dict.gov.ph/cloud-first-policy/" rel="noopener noreferrer"&gt;https://dict.gov.ph/cloud-first-policy/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;National Cybersecurity Plan 2022 (DICT): &lt;a href="https://dict.gov.ph/ncp2022/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://dict.gov.ph/ncp2022/" rel="noopener noreferrer"&gt;https://dict.gov.ph/ncp2022/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;DBM-COA-DOF Joint Circular No. 2013-1 (UACS): &lt;a href="https://www.dbm.gov.ph/index.php/letters-and-circulars/other-releases/295-joint-circular-no-2013-1" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.dbm.gov.ph/index.php/letters-and-circulars/other-releases/295-joint-circular-no-2013-1" rel="noopener noreferrer"&gt;https://www.dbm.gov.ph/index.php/letters-and-circulars/other-releases/295-joint-circular-no-2013-1&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Open Contracting Data Standard (OCDS): &lt;a href="https://standard.open-contracting.org/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://standard.open-contracting.org/" rel="noopener noreferrer"&gt;https://standard.open-contracting.org/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;PhilGEPS: &lt;a href="https://philgeps.gov.ph/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://philgeps.gov.ph/" rel="noopener noreferrer"&gt;https://philgeps.gov.ph/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;PNPKI (eGov PKI): &lt;a href="https://dict.gov.ph/programs/electronic-government/" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://dict.gov.ph/programs/electronic-government/" rel="noopener noreferrer"&gt;https://dict.gov.ph/programs/electronic-government/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;Important: SBN-1330 number may refer to different topics across Congresses; ensure citations target the correct filing/version being amended.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SB 1330 coverage article (context): &lt;a href="https://edgedavao.net/latest-news/2025/09/blockchain-budget-bill-filed-in-the-senate-to-boost-transparency-fund-classrooms/" rel="noopener noreferrer"&gt;https://edgedavao.net/latest-news/2025/09/blockchain-budget-bill-filed-in-the-senate-to-boost-transparency-fund-classrooms/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Background explainer: &lt;a href="https://medium.com/thecapital/blockchain-the-budget-bill-sbn-1330-revolutionizing-fiscal-transparency-in-the-philippines-4968846ad713" rel="noopener noreferrer"&gt;https://medium.com/thecapital/blockchain-the-budget-bill-sbn-1330-revolutionizing-fiscal-transparency-in-the-philippines-4968846ad713&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;COA: &lt;a href="https://www.coa.gov.ph/" rel="noopener noreferrer"&gt;https://www.coa.gov.ph/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;DICT: &lt;a href="https://dict.gov.ph/" rel="noopener noreferrer"&gt;https://dict.gov.ph/&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;strong&gt;⚠️ Important Note&lt;/strong&gt;: This framework transforms SB 1330 from a simple blockchain mandate into a comprehensive anti-corruption system. The focus is on accountability, transparency, and deterrence - not just technology implementation.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;✅ Success Metric&lt;/strong&gt;: When corruption becomes visible, traceable, punishable, and preventable rather than profitable and hidden.&lt;/p&gt;

</description>
      <category>blockchain</category>
      <category>web3</category>
      <category>security</category>
      <category>data</category>
    </item>
    <item>
      <title>🧩 The Habit of Asking **WHY** — Unlocking Purpose, Innovation &amp; Connection</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Tue, 24 Jun 2025 15:28:24 +0000</pubDate>
      <link>https://dev.to/trinly01/the-habit-of-asking-why-unlocking-purpose-innovation-connection-1ln4</link>
      <guid>https://dev.to/trinly01/the-habit-of-asking-why-unlocking-purpose-innovation-connection-1ln4</guid>
      <description>&lt;h2&gt;
  
  
  1. The Power of &lt;em&gt;Why&lt;/em&gt; — More Than Just a Question
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔎 Clarifying Purpose
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Asking &lt;strong&gt;“Why am I doing this?”&lt;/strong&gt; connects daily actions to broader goals and boosts motivation.
&lt;/li&gt;
&lt;li&gt;Simon Sinek’s &lt;strong&gt;Golden Circle&lt;/strong&gt; shows that leaders who start with &lt;em&gt;Why&lt;/em&gt; inspire trust and loyalty by appealing to the emotional (limbic) brain before sharing &lt;em&gt;How&lt;/em&gt; and &lt;em&gt;What&lt;/em&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  ⚙️ Solving Root Problems
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;The &lt;strong&gt;Five Whys&lt;/strong&gt; technique—originating from Toyota—recommends asking “why?” five times to identify underlying causes rather than surface-level symptoms.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🧠 Stimulating Innovation &amp;amp; Critical Thinking
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Persistent questioning challenges assumptions, uncovers hidden truths, and spurs creativity and problem-solving.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  2. When Asking &lt;em&gt;Why&lt;/em&gt; Can Backfire
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ⚠️ Overthinking &amp;amp; Paralysis
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Excessive “why” questions can derail decision-making if context or direction isn't maintained.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🛡️ Triggering Defensiveness
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;In sensitive situations, asking “why” bluntly can sound accusatory. Rephrasing with &lt;strong&gt;“What’s the reason…”&lt;/strong&gt; or &lt;strong&gt;“Help me understand…”&lt;/strong&gt; helps foster openness and psychological safety.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  3. How to Ask &lt;em&gt;Why&lt;/em&gt; Right
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technique&lt;/th&gt;
&lt;th&gt;When to Use&lt;/th&gt;
&lt;th&gt;How It Helps&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Five Whys&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Root-cause analysis&lt;/td&gt;
&lt;td&gt;Systematically drills down to true causes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Socratic questioning&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Learning/reflection&lt;/td&gt;
&lt;td&gt;Builds deep insight through guided inquiry&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Probing questions&lt;/strong&gt; (“Can you give an example?”)&lt;/td&gt;
&lt;td&gt;Feedback &amp;amp; ideas&lt;/td&gt;
&lt;td&gt;Encourages elaboration and clarity&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;Softened why&lt;/strong&gt; (“What’s the intent…?”)&lt;/td&gt;
&lt;td&gt;Sensitive topics&lt;/td&gt;
&lt;td&gt;Reduces defensiveness&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  4. A Narrative That Hooks
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;“Late last night, I stared at my screen debating a ‘share’ button.&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
I paused. &lt;em&gt;Who needs it?&lt;/em&gt;&lt;br&gt;&lt;br&gt;
The next morning, I asked two users. Neither cared.&lt;br&gt;&lt;br&gt;
So I scrapped it.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;And it saved us time, money — and sanity.”&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This mini-story uses emotion, stakes, and payoff to illustrate the moment of choice driven by asking &lt;em&gt;why&lt;/em&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  5. Real-World Impact
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🚀 Innovation
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Asking &lt;em&gt;why&lt;/em&gt; has led to breakthroughs—from electric vehicles to disruptive learning models.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🧩 Team Effectiveness
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Teams that routinely ask &lt;em&gt;why&lt;/em&gt; in retrospectives uncover blockers faster and foster innovation.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  ❤️ Deeper Relationships
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Asking &lt;strong&gt;“Why does that matter to you?”&lt;/strong&gt; shifts conversations from assumptions to empathy and genuine connection.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  6. Soft Tips for Everyday Use
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Be intentional&lt;/strong&gt;: Know when you want deeper insight—and when you just need decisions.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Blend questions&lt;/strong&gt;: Add “how”, “what if”, “why not” to vary tone.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Listen actively&lt;/strong&gt;: Pause, reflect, and validate before asking again.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Frame with care&lt;/strong&gt;: Use prefacing phrases like &lt;em&gt;“Help me understand…”&lt;/em&gt;.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Self-reflect first&lt;/strong&gt;: Ask yourself why something matters before questioning others.&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  7. Science‑Backed Benefits
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Memory &amp;amp; learning&lt;/strong&gt;: “Why” activates deeper brain circuits and improves retention.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Behavioral alignment&lt;/strong&gt;: Explicitly asking why increases follow-through (the mere-measurement effect).
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Purpose alignment&lt;/strong&gt;: Clarifying why aligns tasks with values—boosting motivation and clarity.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  8. Building a Habit
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Ritualize it&lt;/strong&gt;: Begin meetings with “What’s our real why here?”
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Reflect in writing&lt;/strong&gt;: Journal weekly on which whys felt energizing.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Celebrate purpose-led decisions&lt;/strong&gt;: Acknowledge when asking “why” led to better outcomes.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Track results&lt;/strong&gt;: Note if clarifying purpose improved delivery, creativity, or satisfaction.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  9. Final Challenge
&lt;/h2&gt;

&lt;p&gt;Before your next decision—whether it's a feature, ask, or initiative—pause and ask:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Do we really need this?&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Why would it matter or delight someone?&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;If both answers “spark energy” — proceed.
&lt;/li&gt;
&lt;li&gt;If not — refine, delay, or scrap.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🙌 In Summary
&lt;/h2&gt;

&lt;p&gt;Asking &lt;strong&gt;WHY&lt;/strong&gt; gives us:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;🔍 Clarity by addressing root issues
&lt;/li&gt;
&lt;li&gt;⚖️ Purpose-driven focus
&lt;/li&gt;
&lt;li&gt;💡 Innovative thinking
&lt;/li&gt;
&lt;li&gt;💬 Deeper empathy and connection&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Used thoughtfully—structured, softened, and strategic—asking &lt;em&gt;why&lt;/em&gt; transforms tasks into meaningful choices, ideas into breakthroughs.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Ask purposefully. Listen deeply. Act meaningfully.&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>productivity</category>
      <category>career</category>
      <category>programming</category>
      <category>devtips</category>
    </item>
    <item>
      <title># Best Practices for Project Management (Focused on Productivity, Not Meetings)</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Thu, 06 Feb 2025 07:04:53 +0000</pubDate>
      <link>https://dev.to/trinly01/-best-practices-for-project-management-focused-on-productivity-not-meetings-248o</link>
      <guid>https://dev.to/trinly01/-best-practices-for-project-management-focused-on-productivity-not-meetings-248o</guid>
      <description>&lt;h2&gt;
  
  
  1. Essential Roles (No Unnecessary Overhead)
&lt;/h2&gt;

&lt;p&gt;✅ &lt;strong&gt;Project Lead / Manager&lt;/strong&gt; – Ensures project stays on track, removes blockers (not a micromanager).&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Team Members&lt;/strong&gt; – Skilled professionals who do the actual work, empowered to make decisions.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Stakeholder(s)&lt;/strong&gt; – Those who define business goals but don’t micromanage execution.  &lt;/p&gt;

&lt;h3&gt;
  
  
  ❌ What to Avoid:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Useless roles like &lt;strong&gt;"Scrum Master"&lt;/strong&gt; enforcing process over progress.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"Product Owner"&lt;/strong&gt; who exists only to relay messages from executives.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  2. Minimal Set of Artifacts (Only What’s Useful)
&lt;/h2&gt;

&lt;p&gt;✅ &lt;strong&gt;Project Roadmap&lt;/strong&gt; – High-level plan with milestones, kept &lt;strong&gt;flexible&lt;/strong&gt;.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Task Board (Kanban or Simple Backlog)&lt;/strong&gt; – A &lt;strong&gt;visible&lt;/strong&gt; list of tasks that matter, updated as needed.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Deliverables Tracker&lt;/strong&gt; – Tracks what’s actually getting done, not just estimated velocity.  &lt;/p&gt;

&lt;h3&gt;
  
  
  ❌ What to Avoid:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Overloaded &lt;strong&gt;"Sprint Backlogs"&lt;/strong&gt; that never get fully completed.&lt;/li&gt;
&lt;li&gt;Detailed documentation that &lt;strong&gt;no one reads&lt;/strong&gt; (keep it lean &amp;amp; relevant).&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  3. Efficient Rituals (No Time-Wasting Meetings)
&lt;/h2&gt;

&lt;p&gt;✅ &lt;strong&gt;One Weekly Check-In (Max 30 Minutes)&lt;/strong&gt; – Focus on blockers and actual progress, not status updates.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Async Daily Updates (if needed)&lt;/strong&gt; – Quick Slack/Teams updates instead of daily stand-ups.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Retrospectives Only When Needed&lt;/strong&gt; – Instead of scheduled retros, do a &lt;strong&gt;lessons-learned session after milestones&lt;/strong&gt;.  &lt;/p&gt;

&lt;h3&gt;
  
  
  ❌ What to Avoid:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Daily Standups&lt;/strong&gt; where people just say "what they did" without real problem-solving.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sprint Reviews&lt;/strong&gt; that turn into long-winded PowerPoint sessions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Forced Retros&lt;/strong&gt; where no one has real feedback, but they have to say something.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  4. Execution Focused on Real Progress
&lt;/h2&gt;

&lt;p&gt;✅ &lt;strong&gt;Work in Iterations (but Flexible)&lt;/strong&gt; – Weekly or bi-weekly releases, &lt;strong&gt;not fixed 2-week sprints&lt;/strong&gt; that create artificial pressure.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Limit Work in Progress (WIP)&lt;/strong&gt; – Don’t start everything at once; focus on &lt;strong&gt;getting things done&lt;/strong&gt;.&lt;br&gt;&lt;br&gt;
✅ &lt;strong&gt;Fast Decision-Making&lt;/strong&gt; – Team makes &lt;strong&gt;quick, local decisions&lt;/strong&gt; instead of waiting for approvals.  &lt;/p&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;Summary: The Lean, No-BS Framework for Productivity&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Roles:&lt;/strong&gt; Only what’s necessary (&lt;strong&gt;Project Lead, Team, Stakeholders&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Artifacts:&lt;/strong&gt; Just enough structure (&lt;strong&gt;Roadmap, Task Board, Deliverables Tracker&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rituals:&lt;/strong&gt; Only meet when necessary (&lt;strong&gt;Weekly check-ins, Async updates&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Execution:&lt;/strong&gt; Deliver fast, adapt, and avoid bureaucratic overhead.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>management</category>
      <category>productivity</category>
      <category>agile</category>
      <category>devops</category>
    </item>
    <item>
      <title>Software Dev Roles and Salary ranges in the Philippines (2024)</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Tue, 03 Dec 2024 13:32:33 +0000</pubDate>
      <link>https://dev.to/trinly01/software-dev-roles-and-salary-ranges-in-the-philippines-2024-424e</link>
      <guid>https://dev.to/trinly01/software-dev-roles-and-salary-ranges-in-the-philippines-2024-424e</guid>
      <description>&lt;p&gt;Software engineering in the Philippines is evolving rapidly, offering lucrative opportunities for professionals across different skill levels. Whether you're just starting or are already a seasoned expert, this guide outlines the key knowledge areas and salary expectations for &lt;strong&gt;entry-level to principal-level engineers&lt;/strong&gt;. Let’s dive in!&lt;/p&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;1. Entry-Level Engineers&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What to Expect&lt;/strong&gt;: 

&lt;ul&gt;
&lt;li&gt;Basic understanding of &lt;strong&gt;HTML, CSS, and JavaScript&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Familiarity with at least one backend programming language like &lt;strong&gt;Python&lt;/strong&gt; or &lt;strong&gt;PHP&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Knowledge of &lt;strong&gt;Git&lt;/strong&gt; for version control and basic debugging techniques.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Roles&lt;/strong&gt;: Often found in startups or smaller firms, focusing on simple tasks like bug fixing and building small features.&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Salary Range&lt;/strong&gt;: PHP20,000 - PHP40,000/month.&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;2. Junior Engineers&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What to Expect&lt;/strong&gt;:

&lt;ul&gt;
&lt;li&gt;Proficiency in &lt;strong&gt;front-end frameworks&lt;/strong&gt; (e.g., React, Angular).&lt;/li&gt;
&lt;li&gt;Basic database design (e.g., &lt;strong&gt;MySQL&lt;/strong&gt;, &lt;strong&gt;PostgreSQL&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;Experience with &lt;strong&gt;API consumption&lt;/strong&gt; and exposure to Agile methodologies.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Roles&lt;/strong&gt;: Collaborating with teams on building features, handling integration tasks, and starting to handle small modules independently.&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Salary Range&lt;/strong&gt;: PHP40,000 - PHP60,000/month.&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;3. Mid-Level Engineers&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What to Expect&lt;/strong&gt;:

&lt;ul&gt;
&lt;li&gt;Strong expertise in both &lt;strong&gt;front-end and backend frameworks&lt;/strong&gt; (e.g., Node.js, Django).&lt;/li&gt;
&lt;li&gt;Capable of building and deploying APIs and understanding CI/CD pipelines.&lt;/li&gt;
&lt;li&gt;Familiarity with cloud platforms like &lt;strong&gt;AWS&lt;/strong&gt;, &lt;strong&gt;Azure&lt;/strong&gt;, or &lt;strong&gt;GCP&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Roles&lt;/strong&gt;: Responsible for designing modules, optimizing performance, and leading small teams.&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Salary Range&lt;/strong&gt;: PHP60,000 - PHP100,000/month.&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;4. Senior Engineers&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What to Expect&lt;/strong&gt;:

&lt;ul&gt;
&lt;li&gt;Advanced problem-solving and &lt;strong&gt;fullstack expertise&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Proficiency in DevOps tools like &lt;strong&gt;Kubernetes&lt;/strong&gt; and &lt;strong&gt;Docker&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Experienced in designing scalable systems and leading project teams.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Roles&lt;/strong&gt;: Designing end-to-end systems, optimizing infrastructure, and mentoring junior developers.&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Salary Range&lt;/strong&gt;: PHP100,000 - PHP150,000/month.&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;5. Principal Engineers&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;What to Expect&lt;/strong&gt;:

&lt;ul&gt;
&lt;li&gt;Expertise in &lt;strong&gt;system architecture design&lt;/strong&gt; and cross-team leadership.&lt;/li&gt;
&lt;li&gt;Ability to scale applications, optimize cloud costs, and ensure security compliance.&lt;/li&gt;
&lt;li&gt;Establishing technical standards and mentoring teams.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Roles&lt;/strong&gt;: Leading entire engineering teams, defining architecture strategies, and making company-wide technical decisions.&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Salary Range&lt;/strong&gt;: PHP150,000 - PHP250,000+/month.&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;Key Takeaways&lt;/strong&gt;
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Growth Opportunities&lt;/strong&gt;: The transition from junior to senior roles requires mastering not just technical skills but also leadership and strategic thinking.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Salary Variance&lt;/strong&gt;: High-end salaries are typically offered by &lt;strong&gt;multinational companies&lt;/strong&gt; or firms located in tech hubs like &lt;strong&gt;Metro Manila&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;In-Demand Skills&lt;/strong&gt;: Cloud computing (AWS, GCP), DevOps tools (Kubernetes, Terraform), and frontend frameworks (React, Vue) are top skills in demand for 2024.&lt;/li&gt;
&lt;/ol&gt;




&lt;p&gt;With the software engineering field booming in the Philippines, there's no better time to advance your skills and grow your career. Whether you're building your foundation or aiming for leadership roles, the possibilities are endless!&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Sources&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://www.salaryguide.ph" rel="noopener noreferrer"&gt;Philippine Salary Guide 2024&lt;/a&gt;10.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.trendsph.com" rel="noopener noreferrer"&gt;Software Engineer Trends in the Philippines&lt;/a&gt;11.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>programming</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Effective Communication in Daily Stand-Up Meetings for Software Developers</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Fri, 31 May 2024 09:10:21 +0000</pubDate>
      <link>https://dev.to/trinly01/effective-communication-in-daily-stand-up-meetings-for-software-developers-2i8i</link>
      <guid>https://dev.to/trinly01/effective-communication-in-daily-stand-up-meetings-for-software-developers-2i8i</guid>
      <description>&lt;h3&gt;
  
  
  Effective Communication in Daily Stand-Up Meetings for Software Developers
&lt;/h3&gt;

&lt;p&gt;Daily stand-up meetings are a cornerstone of Agile methodology, offering a dedicated platform for team members to synchronize their activities, share progress, and identify any blockers. For software developers, these meetings are critical for ensuring smooth project execution. Mastering the language and flow of stand-up meetings can significantly enhance your communication skills and overall productivity. Here, we’ll explore common phrases and sentences that can help you sound more confident and articulate during these meetings.&lt;/p&gt;

&lt;h4&gt;
  
  
  Starting the Update
&lt;/h4&gt;

&lt;p&gt;When initiating your update, it’s important to clearly and concisely communicate what you worked on previously. This sets the context for your current status and helps the team understand your progress.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"Yesterday, I worked on..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase helps you kick off your update by highlighting your previous day's activities. For example, "Yesterday, I worked on debugging the login feature." By starting with what you accomplished the day before, you provide a clear picture of your recent efforts and set the stage for the current day’s tasks.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"In the last 24 hours, I focused on..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This variation offers a broader time frame, encompassing all activities since the last stand-up. For example, "In the last 24 hours, I focused on implementing the new payment gateway." This phrase can be particularly useful when your work spans across multiple areas or involves significant changes that require more context.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I've been working on..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase is useful for ongoing tasks, indicating continuity in your efforts. For example, "I've been working on optimizing the database queries." Using this phrase can help your team understand that you are in the middle of a larger task that spans several days, providing a sense of continuity and progress.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Current Tasks
&lt;/h4&gt;

&lt;p&gt;Clearly outlining your current tasks helps the team understand what you’re focusing on today. This also sets expectations for what you aim to achieve.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"Today, I plan to..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase clearly indicates your intentions for the day. For example, "Today, I plan to complete the unit tests for the shopping cart feature." By specifying your plan for the day, you give your team a clear understanding of your immediate goals and how they fit into the larger project timeline.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"My main focus today will be..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This variation highlights your primary objective, ensuring that the team knows your top priority. For example, "My main focus today will be on fixing the critical bugs reported by QA." This helps to emphasize the most important task on your agenda, signaling to your team what you believe requires the most attention and effort.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I'm currently working on..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase helps update the team on your immediate activities. For example, "I'm currently working on integrating the third-party API." It provides a snapshot of your current focus and how it contributes to the project’s progress.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Blocking Issues
&lt;/h4&gt;

&lt;p&gt;Identifying and communicating blockers is essential for resolving issues quickly and keeping the project on track.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I'm facing an issue with..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase helps you introduce a specific problem you’re encountering. For example, "I'm facing an issue with the API authentication." By clearly stating your issue, you open the door for team members to offer solutions or assistance.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I'm blocked by..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This direct approach clearly states what’s preventing you from making progress. For example, "I'm blocked by the lack of access to the staging server." Identifying blockers promptly allows the team to address them quickly, ensuring that progress can continue smoothly.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"One challenge I'm encountering is..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase allows for a more detailed explanation of the problem. For example, "One challenge I'm encountering is the inconsistency in the data returned by the API." Providing specific details about your challenges can help the team understand the complexity of the issue and collaborate on finding a solution.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Progress and Achievements
&lt;/h4&gt;

&lt;p&gt;Highlighting your achievements and progress helps maintain a positive tone and demonstrates your contributions to the project.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I've completed..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase succinctly conveys task completion. For example, "I've completed the user interface for the dashboard." Celebrating small victories and completed tasks boosts morale and keeps the team motivated.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I finished the task related to..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This variation provides context for the completed task. For example, "I finished the task related to implementing the new search functionality." Offering context helps the team understand the significance of your completed work and how it fits into the overall project.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I made progress on..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase is useful for ongoing tasks, indicating forward movement. For example, "I made progress on optimizing the loading time for the homepage." Highlighting incremental progress keeps the team informed about the state of long-term tasks and maintains a sense of momentum.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Collaborations and Requests
&lt;/h4&gt;

&lt;p&gt;Effective communication also involves seeking help and coordinating with team members when needed.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I need help with..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This straightforward request for assistance is crucial for overcoming challenges quickly. For example, "I need help with debugging the new feature on the mobile app." Asking for help when needed ensures that issues are resolved efficiently and that you can continue making progress.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"Could someone assist me with..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This polite request for help encourages team collaboration. For example, "Could someone assist me with setting up the CI/CD pipeline?" Encouraging collaboration fosters a supportive team environment where members feel comfortable seeking and offering assistance.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I'm waiting for feedback from..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase helps you indicate dependencies on other team members. For example, "I'm waiting for feedback from the design team on the latest mockups." Communicating dependencies ensures that everyone is aware of what’s needed to move forward and can prioritize their work accordingly.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Next Steps
&lt;/h4&gt;

&lt;p&gt;Outlining your next steps ensures that the team knows what you’ll be focusing on next, helping to maintain alignment and momentum.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"Next, I'll be..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase clearly indicates your upcoming tasks. For example, "Next, I'll be working on the API integration for the notifications system." Providing clear next steps helps the team understand your planned activities and how they align with the project’s goals.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"My next steps are..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This variation helps you outline a series of upcoming tasks. For example, "My next steps are to finalize the database schema and start the data migration." Offering a roadmap of your next steps keeps the team informed about your planned progress and any upcoming milestones.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;"I'll move on to..."&lt;/strong&gt;&lt;br&gt;&lt;br&gt;
This phrase indicates a transition from one task to another. For example, "I'll move on to writing the unit tests for the new module." Communicating your transitions helps the team understand the flow of your work and how each task contributes to the overall project.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Best Practices for Stand-Up Meetings
&lt;/h3&gt;

&lt;p&gt;While using the right phrases and sentences is crucial, adhering to some best practices can further enhance the effectiveness of your stand-up meetings.&lt;/p&gt;

&lt;h4&gt;
  
  
  Be Concise
&lt;/h4&gt;

&lt;p&gt;Stand-up meetings are designed to be short and to the point. Aim to deliver your update in under two minutes, focusing on key information without unnecessary details. This helps keep the meeting efficient and respects everyone’s time.&lt;/p&gt;

&lt;h4&gt;
  
  
  Be Clear
&lt;/h4&gt;

&lt;p&gt;Clarity is essential for effective communication. Use simple and direct language to convey your message. Avoid jargon or overly complex explanations that might confuse team members.&lt;/p&gt;

&lt;h4&gt;
  
  
  Stay Relevant
&lt;/h4&gt;

&lt;p&gt;Ensure that your update is relevant to the team and the project. Share information that impacts the team’s work or the project’s progress. Avoid discussing unrelated topics that don’t contribute to the meeting’s purpose.&lt;/p&gt;

&lt;h4&gt;
  
  
  Be Honest
&lt;/h4&gt;

&lt;p&gt;If you’re facing challenges or are behind schedule, be honest about it. Transparency helps the team address issues promptly and find solutions together. It’s better to acknowledge problems early on rather than let them escalate.&lt;/p&gt;

&lt;h4&gt;
  
  
  Encourage Engagement
&lt;/h4&gt;

&lt;p&gt;Stand-up meetings should be interactive. Encourage team members to ask questions or offer assistance. Fostering an environment of open communication and collaboration strengthens the team dynamic.&lt;/p&gt;

&lt;p&gt;Mastering the art of communication in daily stand-up meetings involves using specific phrases and sentences to clearly convey your status, plans, and any blockers. By practicing these techniques and adhering to best practices, you can enhance your communication skills, contribute more effectively to your team, and ensure the success of your projects. Effective stand-up meetings not only keep everyone informed but also foster a collaborative and supportive team environment, paving the way for successful project outcomes.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Unlock Cross-Micro-Frontend State Sharing!</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Mon, 18 Mar 2024 07:53:23 +0000</pubDate>
      <link>https://dev.to/trinly01/unlock-cross-micro-frontend-state-sharing-1clh</link>
      <guid>https://dev.to/trinly01/unlock-cross-micro-frontend-state-sharing-1clh</guid>
      <description>&lt;h1&gt;
  
  
  Sharing State Across Micro Frontends with MicroLocalStore
&lt;/h1&gt;

&lt;p&gt;In modern web development, the micro-frontend architecture has gained popularity due to its modularity, scalability, and ability to develop large applications as a composition of smaller, independent applications. However, one of the challenges with this approach is sharing state across these micro-frontends in an efficient and secure way.&lt;/p&gt;

&lt;p&gt;Enter MicroLocalStore, a lightweight JavaScript library that provides a shared local storage solution across different origins. In this article, we'll explore how to use MicroLocalStore to share state between micro-frontends, enabling seamless communication and state management.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftlofun5dp80r841fgwq1.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftlofun5dp80r841fgwq1.gif" alt="MicroLocalStore Demo" width="1870" height="604"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What is MicroLocalStore?
&lt;/h2&gt;

&lt;p&gt;MicroLocalStore is a JavaScript library that creates an isolated local storage for each instance, allowing you to store and retrieve data seamlessly across different origins. It's designed specifically for micro-frontend architectures, enabling different micro-apps to share state without conflicts.&lt;/p&gt;

&lt;p&gt;With MicroLocalStore, you can easily manage state listeners, send and receive messages between parent and child windows, and more. It's compatible with both browser and Node.js environments.&lt;/p&gt;

&lt;h2&gt;
  
  
  Installation
&lt;/h2&gt;

&lt;p&gt;You can install MicroLocalStore using npm:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install &lt;/span&gt;micro-local-store
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Alternatively, you can use the unpkg CDN in your HTML file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;script &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://unpkg.com/micro-local-store"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Usage
&lt;/h2&gt;

&lt;p&gt;Let's dive into a simple example to understand how MicroLocalStore works.&lt;/p&gt;

&lt;h3&gt;
  
  
  Setting Up MicroLocalStore
&lt;/h3&gt;

&lt;p&gt;First, we need to create a new instance of MicroLocalStore and provide a unique identifier and an array of allowed URLs that can share the store's state.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;store&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;MicroLocalStore&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;myStore&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://another-example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;]);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Setting and Getting State
&lt;/h3&gt;

&lt;p&gt;You can set the state using the &lt;code&gt;setState&lt;/code&gt; method, which will merge the new state with the existing state.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;key&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;value&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To retrieve the current state, use the &lt;code&gt;getState&lt;/code&gt; method.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;state&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getState&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Listening for State Changes
&lt;/h3&gt;

&lt;p&gt;MicroLocalStore allows you to listen for state changes by registering a listener function with the &lt;code&gt;onChange&lt;/code&gt; method.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;onChange&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;newState&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;newState&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can remove a listener function by calling the &lt;code&gt;offChange&lt;/code&gt; method.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;offChange&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;listener&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Example: Sharing State Between Micro Frontends
&lt;/h2&gt;

&lt;p&gt;Let's consider a scenario where we have two micro-frontends, &lt;code&gt;App1.html&lt;/code&gt; and &lt;code&gt;App2.html&lt;/code&gt;, hosted on the different domains (&lt;code&gt;https://example.com&lt;/code&gt;, &lt;code&gt;https://another-example.com&lt;/code&gt;). We want to share state between these two micro-frontends using MicroLocalStore.&lt;/p&gt;

&lt;h3&gt;
  
  
  App1.html
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"trigger"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Trigger State Change&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"state"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/div&amp;gt;&lt;/span&gt;

    &lt;span class="nt"&gt;&amp;lt;script &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://unpkg.com/micro-local-store"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
      &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;store&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;MicroLocalStore&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;myStore&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://example.com/App1.html&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://another-example.com/App2.html&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
      &lt;span class="p"&gt;]);&lt;/span&gt;

      &lt;span class="c1"&gt;// Get state&lt;/span&gt;
      &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;state&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getState&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
      &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;state&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;innerHTML&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

      &lt;span class="c1"&gt;// Listen for state changes&lt;/span&gt;
      &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;onChange&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;newState&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;state&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;innerHTML&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;newState&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
      &lt;span class="p"&gt;});&lt;/span&gt;

      &lt;span class="c1"&gt;// Set state on button click&lt;/span&gt;
      &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;trigger&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;addEventListener&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;click&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;key&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;value from App1&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
      &lt;span class="p"&gt;});&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  App2.html
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"trigger"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Trigger State Change&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"state"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/div&amp;gt;&lt;/span&gt;

    &lt;span class="nt"&gt;&amp;lt;script &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://unpkg.com/micro-local-store"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
      &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;store&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;MicroLocalStore&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;myStore&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://example.com/App1.html&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://another-example.com/App2.html&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
      &lt;span class="p"&gt;]);&lt;/span&gt;

      &lt;span class="c1"&gt;// Get state&lt;/span&gt;
      &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;state&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getState&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
      &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;state&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;innerHTML&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

      &lt;span class="c1"&gt;// Listen for state changes&lt;/span&gt;
      &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;onChange&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;newState&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;state&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;innerHTML&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;newState&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
      &lt;span class="p"&gt;});&lt;/span&gt;

      &lt;span class="c1"&gt;// Set state on button click&lt;/span&gt;
      &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;trigger&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;addEventListener&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;click&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nx"&gt;store&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;key&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;value from App2&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
      &lt;span class="p"&gt;});&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In this example, both &lt;code&gt;App1.html&lt;/code&gt; and &lt;code&gt;App2.html&lt;/code&gt; create a new instance of MicroLocalStore with the same identifier (&lt;code&gt;"myStore"&lt;/code&gt;). They also specify the URLs of the other micro-frontend that is allowed to share the state.&lt;/p&gt;

&lt;p&gt;Each micro-frontend listens for state changes using the &lt;code&gt;onChange&lt;/code&gt; method and updates its UI accordingly. When the "Trigger State Change" button is clicked, it sets a new state using the &lt;code&gt;setState&lt;/code&gt; method, which will be reflected in both micro-frontends.&lt;/p&gt;

&lt;h2&gt;
  
  
  Cross-Origin Resource Sharing (CORS)
&lt;/h2&gt;

&lt;p&gt;MicroLocalStore uses the &lt;code&gt;postMessage&lt;/code&gt; API to communicate between different windows. This requires that the server hosting your application allows the URLs of the other applications to access your application. This is controlled by the server's CORS policy.&lt;/p&gt;

&lt;p&gt;When creating a new MicroLocalStore instance, you must provide an array of URLs that are allowed to share the store's state. These URLs must be allowed by the server's CORS policy.&lt;/p&gt;

&lt;p&gt;If you're using Express.js, you can use the &lt;code&gt;cors&lt;/code&gt; middleware to set up your CORS policy. Here's an example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;express&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;express&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;cors&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;cors&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;app&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;express&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;corsOptions&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;origin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://another-example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;use&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;cors&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;corsOptions&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;

&lt;span class="c1"&gt;// Your routes here&lt;/span&gt;

&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;listen&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;3000&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Server is running on port 3000&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In this example, &lt;code&gt;https://example.com&lt;/code&gt; and &lt;code&gt;https://another-example.com&lt;/code&gt; are allowed to access your application.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;MicroLocalStore provides a simple and efficient way to share state across micro-frontends, enabling seamless communication and state management. By creating an isolated local storage for each instance and allowing cross-origin communication, MicroLocalStore makes it easy to build modular and scalable web applications using the micro-frontend architecture.&lt;/p&gt;

&lt;p&gt;Give MicroLocalStore a try in your next micro-frontend project and experience the power of shared state management across independent applications.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>What I've Learned Transitioning to Private Sector as a Software Engineer</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Fri, 15 Mar 2024 08:29:14 +0000</pubDate>
      <link>https://dev.to/trinly01/what-ive-learned-transitioning-to-private-sector-as-a-software-engineer-nj1</link>
      <guid>https://dev.to/trinly01/what-ive-learned-transitioning-to-private-sector-as-a-software-engineer-nj1</guid>
      <description>&lt;p&gt;After years working for the government, I made the move to the private sector. This career transition gave me a chance to seriously reflect on development practices and approaches. Here are some of the biggest lessons I realized:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Development Best Practices&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Following good coding habits is crucial for keeping codebases healthy and extensible long-term. Nowadays, I prioritize:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Using TypeScript’s type system properly instead of excessive type castings like &lt;code&gt;as&lt;/code&gt;. Using type guards provides stronger type safety:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kr"&gt;interface&lt;/span&gt; &lt;span class="nx"&gt;User&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt; 
  &lt;span class="nx"&gt;email&lt;/span&gt;&lt;span class="p"&gt;?:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;validateEmail&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;User&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;email&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="k"&gt;in&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c1"&gt;// Type guard checks for optional 'email' prop&lt;/span&gt;
    &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;email&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toUpperCase&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Checking for null/undefined explicitly with optional chaining instead of relying on non-null assertion operators like &lt;code&gt;!&lt;/code&gt;:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;userName&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Anon&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="c1"&gt;// Optional chaining handles null/undefined&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Being smart about utility libraries like Lodash. They can make code more readable for complex operations, but watch out for bundle bloat.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’ve also become way more aware of areas that create technical debt:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Avoiding nested data structures in databases, as they hurt queryability and make it harder to evolve data models cleanly.&lt;/li&gt;
&lt;li&gt;Preventing tight coupling between application logic and the data model to reduce cascading changes when models update.&lt;/li&gt;
&lt;li&gt;Establishing consistent code styles and patterns across the team for better readability and knowledge sharing.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Incorporating automated tests is another big realization, but with a pragmatic approach. Unit, integration, and end-to-end tests are all valuable, but I prioritize what really needs comprehensive test coverage.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Backend Architecture and TypeScript&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;On the backend, I’ve seen great benefits from TypeScript’s static type checking — especially with data transfer objects (DTOs). Defining DTOs with strict types upfront helps catch formatting issues early in requests/responses:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Data Transfer Object &lt;/span&gt;
&lt;span class="kr"&gt;interface&lt;/span&gt; &lt;span class="nx"&gt;CreateUserDTO&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;
  &lt;span class="nx"&gt;email&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;
  &lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// Type-checked request body&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;createUser&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;req&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Request&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="p"&gt;{},&lt;/span&gt; &lt;span class="p"&gt;{},&lt;/span&gt; &lt;span class="nx"&gt;CreateUserDTO&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{...}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That said, TypeScript has limits. Its type system mainly enforces compile-time safety, so extra runtime validation is still smart for handling sketchy or unpredictable data.&lt;/p&gt;

&lt;p&gt;I’ve also solidified my preference for separating concerns on the server-side:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Using controllers strictly for routing/auth logic&lt;/li&gt;
&lt;li&gt;Separate service layer for core business logic&lt;/li&gt;
&lt;li&gt;Repository layer for database access
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Controller&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;getUserController&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;async &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;req&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Request&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;res&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Response&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;getUserService&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;req&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;params&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="nx"&gt;res&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// Service&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;getUserService&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;async &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;userRepository&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;findById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="c1"&gt;// ...business logic&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// Repository &lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;userRepository&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;findById&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="cm"&gt;/* DB query */&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Databases&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;My experience has only reinforced that SQL’s tabular relational model is better than NoSQL’s nested data approach for most applications.&lt;/p&gt;

&lt;p&gt;While NoSQL’s flexibility to evolve schemas easily is appealing early on, those advantages get outweighed by drawbacks around query efficiency and performance at scale. Normalized data models, leveraging database relationships and SQL’s powerful querying, provide a sturdier long-term foundation.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"pr_001"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Product 1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; 
  &lt;/span&gt;&lt;span class="nl"&gt;"categories"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"Electronics"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Computers"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"specs"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"weight"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mf"&gt;2.5&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"dimensions"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"length"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;12&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"width"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;8&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"height"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"variants"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"pr_001_red"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"color"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"red"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"pr_001_blu"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"color"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"blue"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;While this flexible schema is convenient during initial development, it becomes increasingly problematic over time:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Querying across products and variants requires complex join-like operations&lt;/li&gt;
&lt;li&gt;Updating nested specs or adding new variant properties is cumbersome&lt;/li&gt;
&lt;li&gt;Aggregating and analyzing catalog data is inefficient&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In a normalized SQL schema, the same product data could be split into separate tables like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Products (id, name, weight)
Categories (id, name)
Product_Categories (product_id, category_id)
Specs (product_id, length, width, height)
Variants (id, product_id, color)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This separation allows queries like “Get all products under 3 lbs with variant colors” to be executed efficiently using JOINs. New properties can be added seamlessly, and analyzing the catalog data is much simpler with SQL’s advanced querying capabilities.&lt;/p&gt;

&lt;p&gt;So while NoSQL’s flexible schema provides early convenience, the long-term sustainability and performance advantages of SQL’s relational model become increasingly evident over time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Frontend Development&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;For frontend architecture, I’ve looked at the tradeoffs between micro-frontends and monolithic frontends:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Micro-Frontends&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Independent deployment&lt;/li&gt;
&lt;li&gt;Gradual framework updates&lt;/li&gt;
&lt;li&gt;Limit regression risks&lt;/li&gt;
&lt;li&gt;But increases complexity&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Monolithic Frontend&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Simpler, fewer duplicates&lt;/li&gt;
&lt;li&gt;Easier to bundle/deploy&lt;/li&gt;
&lt;li&gt;Makes sense for low-complexity&lt;/li&gt;
&lt;li&gt;Can inhibit large-scale evolution&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’ve also got tons of experience with both Vue.js and React recently. While React’s huge ecosystem and adoption are clear pros, I prefer Vue’s coherent reactivity model and separation of concerns between script, template, and styles:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;{{ upperCaseName }}&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script &lt;/span&gt;&lt;span class="na"&gt;setup&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;computed&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;vue&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;props&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;defineProps&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;String&lt;/span&gt;
&lt;span class="p"&gt;})&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;upperCaseName&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;computed&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;props&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toUpperCase&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In my experience, Vue provides an easier entry point for rapid development, while its opinionated state management, watchers, and computed properties help avoid subtle bugs. With TypeScript, React’s hooks paradigm can get overly complex compared to Vue’s more straightforward reactivity.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Project Management&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;From an execution standpoint, I’ve gained a greater appreciation for diligent ticket grooming and documentation. Well-defined tickets capturing clear requirements, repro steps, and user narratives promote shared understanding and productive collaboration.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Bug Ticket Template:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;🐞 Summary Description:&lt;/p&gt;

&lt;p&gt;Profile Image Upload Failing&lt;/p&gt;

&lt;p&gt;Description:&lt;/p&gt;

&lt;p&gt;When attempting to upload a new profile image from the Settings page, the upload fails with an error alert.&lt;/p&gt;

&lt;p&gt;👣 Steps to Reproduce:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Go to Profile Settings page&lt;/li&gt;
&lt;li&gt;Click “Upload New Image”&lt;/li&gt;
&lt;li&gt;Select an image file&lt;/li&gt;
&lt;li&gt;Click “Save Changes”&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;🚫 Actual Result:&lt;/p&gt;

&lt;p&gt;Error alert “Upload Failed” is displayed and existing profile image remains.&lt;/p&gt;

&lt;p&gt;✅ Expected Result:&lt;/p&gt;

&lt;p&gt;New image is displayed and replaces the existing profile image.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Task Ticket Template:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;📖 Description:&lt;/p&gt;

&lt;p&gt;In order to improve product page experience 🎯, as a front-end developer 👨‍💻, I need to add an image zoom feature when clicking product images ✅.&lt;/p&gt;

&lt;p&gt;✅ Acceptance Criteria:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;User can click thumbnail to zoom&lt;/li&gt;
&lt;li&gt;Overlay displays zoomed image&lt;/li&gt;
&lt;li&gt;User can move and resize overlay&lt;/li&gt;
&lt;li&gt;Overlay hides when clicking off&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;📋 Other Information&lt;/p&gt;

&lt;p&gt;Attach Figma designs for zoom overlay styles/interactions.&lt;/p&gt;

&lt;p&gt;Breaking down larger efforts into granular sub-tasks with estimations helps manage stakeholder expectations and workloads. Working off vague or thinly-documented tickets inevitably leads to misalignment and rework later.&lt;br&gt;
I've also refined my perspective on strategic &lt;em&gt;debugging workflows&lt;/em&gt;. While IDE debuggers with breakpoints are powerful, well-placed console.log()statements remain invaluable - especially for analyzing production issues or reasoning about async behavior.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Looking Ahead&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Since transitioning to the private sector, all these lessons around best practices, architectural patterns, technology tradeoffs, and processes have crystallized for me. But I recognize this industry moves rapidly, so any rigid dogma will become obsolete quick.&lt;br&gt;
I aim to keep an open, growth mindset - continuously re-evaluating approaches while pragmatically applying techniques that fit the current context best. This intentional reflection period has reinvigorated my passion while giving me a refined, balanced perspective on full-stack development.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Data Transformation Magic: Simplify Complex Data with Remap.JS!</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Fri, 03 Nov 2023 14:59:30 +0000</pubDate>
      <link>https://dev.to/trinly01/data-transformation-magic-simplify-complex-data-with-remapjs-o1a</link>
      <guid>https://dev.to/trinly01/data-transformation-magic-simplify-complex-data-with-remapjs-o1a</guid>
      <description>&lt;p&gt;Data mapping can be a challenging and complex task, especially when dealing with nested data structures, arrays, and deeply nested objects. In scenarios where you need to restructure or transform data from one format to another, the complexity can quickly become overwhelming. This is where the Remap.JS library comes to the rescue.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.npmjs.com/package/@trinly01/remap.js"&gt;https://www.npmjs.com/package/@trinly01/remap.js&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Remap.JS Library Tutorial
&lt;/h1&gt;

&lt;p&gt;The Remap.JS library is a versatile JavaScript utility that simplifies data transformation, making it suitable for a wide range of use cases. In this tutorial, we'll explore how to use the library to remap and notate data, allowing you to transform complex data structures easily.&lt;/p&gt;

&lt;h2&gt;
  
  
  Table of Contents
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Installation&lt;/li&gt;
&lt;li&gt;Remap Function&lt;/li&gt;
&lt;li&gt;Notate Function&lt;/li&gt;
&lt;li&gt;Tutorial Example&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Installation
&lt;/h2&gt;

&lt;p&gt;To get started with the Remap.JS library, you'll need to install it into your project. You can install it using npm or yarn:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt; @trinly01/remap.js
&lt;span class="c"&gt;# or&lt;/span&gt;
yarn add @trinly01/remap.js
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once the library is installed, you can import it into your JavaScript file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;remap&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;notate&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@trinly01/remap.js&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Remap Function
&lt;/h2&gt;

&lt;p&gt;The &lt;code&gt;remap&lt;/code&gt; function allows you to transform an array of objects into a new array with the mapped data according to the specified key mapping configuration. It's a powerful tool for simplifying complex data structures.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage:
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;transformedData&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;remap&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;sourceArray&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;keyMap&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;sourceArray&lt;/code&gt; (Array): The array of source objects to remap.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;keyMap&lt;/code&gt; (Object): The key mapping configuration defining how to map the source data to the destination object.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Notate Function
&lt;/h2&gt;

&lt;p&gt;The &lt;code&gt;notate&lt;/code&gt; function is used to create and assign values to objects with specific key notations. It's highly flexible and adaptable for various use cases.&lt;/p&gt;

&lt;h3&gt;
  
  
  Usage:
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;notate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;notation&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;notation&lt;/code&gt; (String or Object): The key notation in the destination object. If it's an object, you can set multiple values at once. If it's a single path notation (string), the &lt;code&gt;value&lt;/code&gt; parameter is required.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;value&lt;/code&gt; (Any): The value to assign to the destination object. Required when &lt;code&gt;notation&lt;/code&gt; is a single path notation (string).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;result&lt;/code&gt; (Object, optional): The result object where the data will be assigned.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Tutorial Example
&lt;/h2&gt;

&lt;p&gt;Let's put the Remap.JS library to use with a simple example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;remap&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;notate&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@trinly01/remap.js&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;sourceArray&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;John Doe&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;contact&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="na"&gt;email&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;john@work.com&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;phone&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;123-456-7890&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="c1"&gt;// Add more source data objects here&lt;/span&gt;
&lt;span class="p"&gt;];&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;keyMap&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.id&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;id&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.name&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;name&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.email&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;contact.email&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.phone&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;contact.phone&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="c1"&gt;// Remap the source data&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;transformedData&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;remap&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;sourceArray&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;keyMap&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Transformed Data:&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;transformedData&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// Notate single values&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{};&lt;/span&gt;
&lt;span class="nx"&gt;notate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.id&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;notate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.name&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;John Doe&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;notate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.email&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;john@work.com&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;notate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.phone&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;123-456-7890&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Result after notating single values:&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// Notate multiple values using an object&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;obj&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{};&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;multipleValues&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.id&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.name&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;John Doe&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.email&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;john@work.com&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Profile.phone&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;123-456-7890&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="nx"&gt;notate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;multipleValues&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;obj&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Result after notating multiple values:&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;obj&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This example demonstrates how to use the Remap.JS library to remap and notate data, making data transformation tasks simpler and more flexible.&lt;/p&gt;

&lt;p&gt;That's it! You've learned how to use the Remap.JS library to streamline data transformation and notating. This versatile utility can be a valuable asset in various data manipulation tasks.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Big-O Notation</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Thu, 07 Sep 2023 13:17:11 +0000</pubDate>
      <link>https://dev.to/trinly01/big-o-notation-1cki</link>
      <guid>https://dev.to/trinly01/big-o-notation-1cki</guid>
      <description>&lt;p&gt;Sure! Big O notation is used to describe the time complexity of algorithms. In JavaScript, various algorithms may exhibit different time complexities. Here are some examples with explanations:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Constant Time O(1):
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;constantTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt; &lt;span class="c1"&gt;// Accessing the first element in the array, regardless of the array size, takes constant time.&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Linear Time O(n):
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;linearTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt; &lt;span class="c1"&gt;// The function loops through the entire array, and the running time grows linearly with the array size.&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Quadratic Time O(n^2):
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;quadraticTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;j&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt; &lt;span class="c1"&gt;// Nested loops make the function run n^2 times, where n is the array size.&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Logarithmic Time O(log n):
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;binarySearch&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;target&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;left&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;right&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;left&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;=&lt;/span&gt; &lt;span class="nx"&gt;right&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;floor&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;left&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;right&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;mid&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="nx"&gt;target&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;mid&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;mid&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;target&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nx"&gt;left&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="nx"&gt;right&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="c1"&gt;// In a binary search, the search space is divided in half at each step, making it logarithmic time complexity.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Polynomial Time O(n^k):
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;polynomialTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;k&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;k&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;k&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;j&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;k&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt; &lt;span class="c1"&gt;// Triple nested loop makes the function run n^3 times, where n is the array size.&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These examples demonstrate how Big O notation helps us understand how the performance of an algorithm changes as the size of the input data increases. It allows us to analyze and compare different algorithms to choose the most efficient one for a particular problem.&lt;/p&gt;

&lt;p&gt;Time Complexity and Space Complexity are two fundamental concepts in computer science that help analyze the efficiency and resource usage of algorithms and data structures. Let's delve into these concepts with JavaScript examples:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Time Complexity:&lt;/strong&gt;&lt;br&gt;
Time complexity measures how the running time of an algorithm or function scales with the input size. It provides an estimate of the number of basic operations (e.g., comparisons, assignments) an algorithm requires to complete its task, as a function of the input size. Common time complexities are denoted using Big O notation (e.g., O(1), O(n), O(n^2)).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Examples:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Constant Time O(1):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;  &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;constantTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt; &lt;span class="c1"&gt;// Regardless of the array size, accessing the first element takes constant time.&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Linear Time O(n):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;  &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;linearTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt; &lt;span class="c1"&gt;// The function loops through the entire array, taking time proportional to 'n', the array size.&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Quadratic Time O(n^2):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;  &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;quadraticTimeExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;j&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
              &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;j&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt; &lt;span class="c1"&gt;// Double nested loop makes the function run 'n' times for each 'n' element, resulting in 'n^2' time complexity.&lt;/span&gt;
          &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;2. Space Complexity:&lt;/strong&gt;&lt;br&gt;
Space complexity measures the amount of memory an algorithm uses with respect to the input size. It's concerned with the growth of memory usage as the input size increases. Similar to time complexity, space complexity is also represented using Big O notation.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Examples:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Constant Space O(1):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;  &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;constantSpaceExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="nx"&gt;result&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c1"&gt;// The 'result' variable consumes a fixed amount of memory, regardless of 'n'.&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Linear Space O(n):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;  &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;linearSpaceExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[];&lt;/span&gt;
      &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// The 'arr' array grows linearly with 'n', leading to linear space complexity.&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;arr&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Quadratic Space O(n^2):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;  &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;quadraticSpaceExample&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;matrix&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[];&lt;/span&gt;
      &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="nx"&gt;matrix&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Array&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;fill&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt; &lt;span class="c1"&gt;// Creating a 2D matrix with 'n' rows and 'n' columns leads to quadratic space complexity.&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;matrix&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Understanding time and space complexity is crucial for designing efficient algorithms and data structures, as it helps in making informed choices about which algorithm to use for a given problem and how it will perform as the input size grows.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Deploying Node.js App</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Thu, 27 Jul 2023 07:52:47 +0000</pubDate>
      <link>https://dev.to/trinly01/deploying-nodejs-app-dln</link>
      <guid>https://dev.to/trinly01/deploying-nodejs-app-dln</guid>
      <description>&lt;p&gt;Below is a table comparing how to deploy a Node.js app on AWS, GCP, and Azure, along with some of the best services to use for each platform:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Service&lt;/th&gt;
&lt;th&gt;AWS&lt;/th&gt;
&lt;th&gt;GCP&lt;/th&gt;
&lt;th&gt;Azure&lt;/th&gt;
&lt;th&gt;Steps on Setting Up&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Compute Service&lt;/td&gt;
&lt;td&gt;Amazon EC2&lt;/td&gt;
&lt;td&gt;Google Compute Engine (GCE)&lt;/td&gt;
&lt;td&gt;Azure Virtual Machines (VMs)&lt;/td&gt;
&lt;td&gt;1. Create a virtual machine instance (EC2) &lt;br&gt; 2. Set up Node.js on the instance&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Serverless&lt;/td&gt;
&lt;td&gt;AWS Lambda&lt;/td&gt;
&lt;td&gt;Google Cloud Functions&lt;/td&gt;
&lt;td&gt;Azure Functions&lt;/td&gt;
&lt;td&gt;1. Create a serverless function &lt;br&gt; 2. Package and deploy your Node.js app&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Container Orchestration&lt;/td&gt;
&lt;td&gt;Amazon ECS or EKS&lt;/td&gt;
&lt;td&gt;Google Kubernetes Engine (GKE)&lt;/td&gt;
&lt;td&gt;Azure Kubernetes Service (AKS)&lt;/td&gt;
&lt;td&gt;1. Create a container cluster &lt;br&gt; 2. Deploy your Node.js app using Kubernetes manifests&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;App Platform&lt;/td&gt;
&lt;td&gt;AWS Elastic Beanstalk&lt;/td&gt;
&lt;td&gt;Google App Engine&lt;/td&gt;
&lt;td&gt;Azure App Service&lt;/td&gt;
&lt;td&gt;1. Create an app environment &lt;br&gt; 2. Deploy your Node.js app to the platform&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Database&lt;/td&gt;
&lt;td&gt;Amazon RDS or DynamoDB&lt;/td&gt;
&lt;td&gt;Google Cloud SQL or Firestore&lt;/td&gt;
&lt;td&gt;Azure SQL Database or Cosmos DB&lt;/td&gt;
&lt;td&gt;1. Create a database instance &lt;br&gt; 2. Connect and deploy your Node.js app&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;File Storage&lt;/td&gt;
&lt;td&gt;Amazon S3 or EFS&lt;/td&gt;
&lt;td&gt;Google Cloud Storage&lt;/td&gt;
&lt;td&gt;Azure Blob Storage&lt;/td&gt;
&lt;td&gt;1. Create a storage bucket/container &lt;br&gt; 2. Upload your app's files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Networking&lt;/td&gt;
&lt;td&gt;Amazon VPC&lt;/td&gt;
&lt;td&gt;Google Virtual Private Cloud (VPC)&lt;/td&gt;
&lt;td&gt;Azure Virtual Network&lt;/td&gt;
&lt;td&gt;1. Set up a virtual network &lt;br&gt; 2. Configure network rules for your app&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Load Balancing&lt;/td&gt;
&lt;td&gt;Amazon ELB or ALB&lt;/td&gt;
&lt;td&gt;Google Cloud Load Balancing&lt;/td&gt;
&lt;td&gt;Azure Load Balancer or Application Gateway&lt;/td&gt;
&lt;td&gt;1. Create a load balancer &lt;br&gt; 2. Add your app instances to the balancer&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Monitoring&lt;/td&gt;
&lt;td&gt;Amazon CloudWatch&lt;/td&gt;
&lt;td&gt;Google Cloud Monitoring&lt;/td&gt;
&lt;td&gt;Azure Monitor&lt;/td&gt;
&lt;td&gt;1. Set up monitoring for your app &lt;br&gt; 2. Configure alerting and logs&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These steps are simplified overviews of the process and may involve more specific configurations depending on your application's needs and the cloud provider's UI/CLI/API. Always refer to the official documentation of the respective cloud provider for detailed and up-to-date instructions.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TB
    subgraph Users
        user1[User 1]
        user2[User 2]
        user3[User 3]
    end

    subgraph Frontend
        vue1[Vue Client 1]
        vue2[Vue Client 2]
        vue3[Vue Client 3]
    end

    subgraph AWS
        subgraph Networking
            vpc[VPC]
            ig[Internet Gateway]
            rt[Route Tables]
            nat[NAT Gateway]
            subnet1[Public Subnet]
            subnet2[Private Subnet]
        end

        subgraph Compute
            elb[Elastic Load Balancing]
            asg[Auto Scaling Group]
            ec2_1[EC2 Instance 1]
            ec2_2[EC2 Instance 2]
            ec2_3[EC2 Instance 3]
        end

        subgraph Storage
            s3[S3 Bucket]
            efs[EFS]
        end

        subgraph Database
            db[Amazon RDS or DynamoDB]
            elasticache[ElastiCache]
        end

        subgraph Messaging
            sns[Amazon SNS]
            sqs[Amazon SQS]
        end

        subgraph Realtime
            apigw[API Gateway]
            lambda[AWS Lambda]
            iot[AWS IoT Core]
        end

        subgraph Security
            iam[IAM]
            waf[WAF]
        end

        subgraph Deployment
            cicd[CI/CD Pipeline]
        end

        subgraph Monitoring
            cloudwatch[CloudWatch]
            xray[AWS X-Ray]
        end
    end

    user1 -.- vue1
    user2 -.- vue2
    user3 -.- vue3

    vue1 --&amp;gt; elb
    vue2 --&amp;gt; elb
    vue3 --&amp;gt; elb

    elb --&amp;gt; asg
    asg --&amp;gt; ec2_1
    asg --&amp;gt; ec2_2
    asg --&amp;gt; ec2_3

    ec2_1 --&amp;gt; db
    ec2_2 --&amp;gt; db
    ec2_3 --&amp;gt; db

    ec2_1 --&amp;gt; elasticache
    ec2_2 --&amp;gt; elasticache
    ec2_3 --&amp;gt; elasticache

    ec2_1 --&amp;gt; efs
    ec2_2 --&amp;gt; efs
    ec2_3 --&amp;gt; efs

    ec2_1 --&amp;gt; s3
    ec2_2 --&amp;gt; s3
    ec2_3 --&amp;gt; s3

    ec2_1 --&amp;gt; sns
    ec2_2 --&amp;gt; sns
    ec2_3 --&amp;gt; sns

    sns --&amp;gt; sqs
    sqs --&amp;gt; lambda
    lambda --&amp;gt; iot

    iot --&amp;gt; vue1
    iot --&amp;gt; vue2
    iot --&amp;gt; vue3

    apigw --&amp;gt; lambda
    apigw --&amp;gt; waf

    cicd -.-&amp;gt; ec2_1
    cicd -.-&amp;gt; ec2_2
    cicd -.-&amp;gt; ec2_3

    iam -.-&amp;gt; ec2_1
    iam -.-&amp;gt; ec2_2
    iam -.-&amp;gt; ec2_3
    iam -.-&amp;gt; lambda
    iam -.-&amp;gt; iot
    iam -.-&amp;gt; apigw

    cloudwatch -.-&amp;gt; vpc
    cloudwatch -.-&amp;gt; ec2_1
    cloudwatch -.-&amp;gt; ec2_2
    cloudwatch -.-&amp;gt; ec2_3
    cloudwatch -.-&amp;gt; elb
    cloudwatch -.-&amp;gt; asg
    cloudwatch -.-&amp;gt; db
    cloudwatch -.-&amp;gt; elasticache
    cloudwatch -.-&amp;gt; s3
    cloudwatch -.-&amp;gt; efs
    cloudwatch -.-&amp;gt; sns
    cloudwatch -.-&amp;gt; sqs
    cloudwatch -.-&amp;gt; lambda
    cloudwatch -.-&amp;gt; iot
    cloudwatch -.-&amp;gt; apigw
    cloudwatch -.-&amp;gt; waf
    cloudwatch -.-&amp;gt; cicd

    xray -.-&amp;gt; ec2_1
    xray -.-&amp;gt; ec2_2
    xray -.-&amp;gt; ec2_3
    xray -.-&amp;gt; lambda
    xray -.-&amp;gt; apigw

    classDef boxStyle stroke:#000,stroke-width:2px,color:#000,fill:#bbb;
    class Users,Frontend boxStyle
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here's an explanation of the improved architecture diagram:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Frontend&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The frontend is built using &lt;strong&gt;Vue.js&lt;/strong&gt;, with separate Vue client applications for each user.&lt;/li&gt;
&lt;li&gt;The &lt;strong&gt;Vue clients&lt;/strong&gt; communicate with the backend API through the &lt;strong&gt;Elastic Load Balancing&lt;/strong&gt; and receive &lt;strong&gt;real-time updates&lt;/strong&gt; through &lt;strong&gt;AWS IoT Core&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Backend&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The backend is implemented using &lt;strong&gt;Node.js&lt;/strong&gt;, running on &lt;strong&gt;EC2 instances&lt;/strong&gt; managed by an &lt;strong&gt;Auto Scaling Group&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;The &lt;strong&gt;Node.js backend&lt;/strong&gt; communicates with the database (&lt;strong&gt;Amazon RDS&lt;/strong&gt; or &lt;strong&gt;DynamoDB&lt;/strong&gt;) for storing and retrieving chat messages, user information, channels, and other persistent data.&lt;/li&gt;
&lt;li&gt;The &lt;strong&gt;Node.js backend&lt;/strong&gt; also interacts with &lt;strong&gt;Amazon S3&lt;/strong&gt; for storing and serving static assets, such as images and files shared within the chat system.&lt;/li&gt;
&lt;li&gt;The &lt;strong&gt;Node.js backend&lt;/strong&gt; publishes &lt;strong&gt;real-time updates&lt;/strong&gt; to &lt;strong&gt;Amazon SNS&lt;/strong&gt;, which triggers &lt;strong&gt;AWS Lambda&lt;/strong&gt; functions for broadcasting messages to connected clients via &lt;strong&gt;AWS IoT Core&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;API Gateway&lt;/strong&gt; and &lt;strong&gt;Lambda&lt;/strong&gt; functions can be used for additional functionality, such as creating channels, managing groups, and other operations.&lt;/li&gt;
&lt;li&gt;The backend instances can access shared file storage through &lt;strong&gt;Amazon Elastic File System (EFS)&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Frequently accessed data can be cached using &lt;strong&gt;Amazon ElastiCache&lt;/strong&gt; for improved performance.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Networking&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The entire architecture is hosted within an &lt;strong&gt;AWS Virtual Private Cloud (VPC)&lt;/strong&gt; for isolation and security.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Public&lt;/strong&gt; and &lt;strong&gt;private subnets&lt;/strong&gt; are created, with the public subnet hosting the Elastic Load Balancing and the private subnet hosting the EC2 instances and other services.&lt;/li&gt;
&lt;li&gt;An &lt;strong&gt;Internet Gateway&lt;/strong&gt; is attached to the VPC to allow internet access.&lt;/li&gt;
&lt;li&gt;A &lt;strong&gt;NAT Gateway&lt;/strong&gt; is used to enable EC2 instances in the private subnet to access the internet for updates and other outbound traffic.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Route Tables&lt;/strong&gt; are configured to route traffic appropriately.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Compute&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Elastic Load Balancing&lt;/strong&gt; distributes incoming traffic across multiple EC2 instances, ensuring high availability and scalability.&lt;/li&gt;
&lt;li&gt;An &lt;strong&gt;Auto Scaling Group&lt;/strong&gt; is used to automatically scale the number of EC2 instances based on demand, ensuring the system can handle increased traffic.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Storage&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Amazon S3 (Simple Storage Service)&lt;/strong&gt; is used for storing and serving static assets, such as images and files shared within the chat system.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Amazon Elastic File System (EFS)&lt;/strong&gt; provides shared file storage across EC2 instances.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Database&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Amazon RDS (Relational Database Service)&lt;/strong&gt; or &lt;strong&gt;DynamoDB (NoSQL database)&lt;/strong&gt; can be used to store chat messages, user information, channels, and other persistent data.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Amazon ElastiCache&lt;/strong&gt; is used for caching frequently accessed data, improving performance.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Messaging&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Amazon SNS (Simple Notification Service)&lt;/strong&gt; and &lt;strong&gt;SQS (Simple Queue Service)&lt;/strong&gt; are used for asynchronous communication and decoupling components.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;SNS&lt;/strong&gt; publishes messages to &lt;strong&gt;SQS&lt;/strong&gt;, which triggers &lt;strong&gt;AWS Lambda&lt;/strong&gt; functions for real-time processing and broadcasting messages to connected clients.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Real-time Communication&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AWS IoT Core&lt;/strong&gt; is used for &lt;strong&gt;real-time bi-directional communication&lt;/strong&gt; between the server and clients, enabling real-time chat and file sharing.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;API Gateway&lt;/strong&gt; and &lt;strong&gt;Lambda&lt;/strong&gt; functions can be used for additional real-time functionality, such as creating channels, managing groups, and other operations.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Security&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AWS Identity and Access Management (IAM)&lt;/strong&gt; is used for controlling access to AWS resources, ensuring secure access to the EC2 instances, Lambda functions, IoT Core, and API Gateway.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS Web Application Firewall (WAF)&lt;/strong&gt; protects the API Gateway from common web exploits and malicious traffic, enhancing the security of the application.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Deployment&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A &lt;strong&gt;Continuous Integration/Continuous Deployment (CI/CD) Pipeline&lt;/strong&gt; is used for automated building, testing, and deploying the application to the EC2 instances.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Monitoring&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Amazon CloudWatch&lt;/strong&gt; is used for monitoring the entire infrastructure, including EC2 instances, load balancers, databases, and other services, providing insights into performance, errors, and resource utilization.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS X-Ray&lt;/strong&gt; is used for debugging and analyzing the performance of the application and its underlying services, helping identify and troubleshoot issues.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This improved architecture leverages various AWS services to provide a scalable, highly available, secure, and fault-tolerant real-time chat system. It addresses aspects such as caching, file storage, security, deployment, and monitoring, ensuring a robust and efficient solution. The architecture remains modular and extensible, allowing for future enhancements and integrations with other AWS services as needed.&lt;/p&gt;

&lt;p&gt;Note: The specific configurations and implementation details for each service would need to be tailored based on the project's requirements, security considerations, and best practices.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>tutorial</category>
      <category>devops</category>
      <category>webdev</category>
    </item>
    <item>
      <title>My Coding Challenge Interview! Sheesh!</title>
      <dc:creator>Trinmar Boado</dc:creator>
      <pubDate>Thu, 20 Jul 2023 15:34:59 +0000</pubDate>
      <link>https://dev.to/trinly01/my-coding-challenge-interview-sheesh-44dg</link>
      <guid>https://dev.to/trinly01/my-coding-challenge-interview-sheesh-44dg</guid>
      <description>&lt;h2&gt;
  
  
  I am very happy I made it!
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="cm"&gt;/*
You are working on an authentication system and there is a set of rules the users have to follow when picking a new password:

1. It has to be at least 16 characters long.
2. The password cannot contain the word "password". This rule is not case-sensitive.
3. The same character cannot be used more than 4 times. This rule is case-sensitive, "a" and "A" are different characters.
4. The password has to contain at least one uppercase and one lowercase letter.
5. The password has to contain at least one of the following special characters "*","#","@".

Write a function that takes in a password and returns a collection of any rule numbers that are not met.

password_1 = "Strongpwd9999#abc"             ==&amp;gt; []
password_2 = "Less10#"                       ==&amp;gt; [1]
password_3 = "Password@"                     ==&amp;gt; [1,2]
password_4 = "#PassWord011111112222223x"     ==&amp;gt; [2,3]
password_5 = "password#1111111"              ==&amp;gt; [2,3,4]
password_6 = "aaaapassword$$"                ==&amp;gt; [1,2,3,4,5]
password_7 = "LESS10#"                       ==&amp;gt; [1,4]
password_8 = "SsSSSt#passWord"               ==&amp;gt; [1,2]


All test cases:

validate(password_1) ==&amp;gt; []
validate(password_2) ==&amp;gt; [1]
validate(password_3) ==&amp;gt; [1,2]
validate(password_4) ==&amp;gt; [2,3]
validate(password_5) ==&amp;gt; [2,3,4]
validate(password_6) ==&amp;gt; [1,2,3,4,5]
validate(password_7) ==&amp;gt; [1,4]
validate(password_8) ==&amp;gt; [1,2]


Complexity variables:

N = length of the password

time O(n)
space O()

 */&lt;/span&gt;

&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;use strict&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;


&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_1&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Strongpwd9999#abc&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_2&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Less10#&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_3&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Password@&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_4&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;#PassWord011111112222223x&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_5&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;password#1111111&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_6&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;aaaapassword$$&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_7&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;LESS10#&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;password_8&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;SsSSSt#passWord&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;







&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;arrRules&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[]&lt;/span&gt; 

  &lt;span class="c1"&gt;// 1. It has to be at least 16 characters long.&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;16&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nx"&gt;arrRules&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

  &lt;span class="c1"&gt;// 2. The password cannot contain the word "password". This rule is not case-sensitive.&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;toLowerCase&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nx"&gt;includes&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;password&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="nx"&gt;arrRules&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;


  &lt;span class="c1"&gt;// 3. The same character cannot be used more than 4 times. This rule is case-sensitive, "a" and "A" are different characters.&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;charCounter&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;

  &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;char&lt;/span&gt; &lt;span class="k"&gt;of&lt;/span&gt; &lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;charCounter&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;char&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;charCounter&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;char&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;++&lt;/span&gt; 
    &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;charCounter&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;char&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;charCounter&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;char&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;arrRules&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
      &lt;span class="k"&gt;break&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;



  &lt;span class="c1"&gt;// 4. The password has to contain at least one uppercase and one lowercase letter.&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;hasUpperCase&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;hasLowerCase&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;

  &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;char&lt;/span&gt; &lt;span class="k"&gt;of&lt;/span&gt; &lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;decCode&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;char&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;charCodeAt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; 

    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;decCode&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;64&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nx"&gt;decCode&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;91&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;hasUpperCase&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;decCode&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;96&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nx"&gt;decCode&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;123&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;hasLowerCase&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;hasUpperCase&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nx"&gt;hasLowerCase&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;break&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;

  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;hasUpperCase&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nx"&gt;hasLowerCase&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;arrRules&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;

  &lt;span class="c1"&gt;// 5. The password has to contain at least one of the following special characters "*","#","@".&lt;/span&gt;

  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;hasSpecialChar&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;

  &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;char&lt;/span&gt; &lt;span class="k"&gt;of&lt;/span&gt; &lt;span class="nx"&gt;password&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;

    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;([&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;*&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;#&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nx"&gt;includes&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;char&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;hasSpecialChar&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
      &lt;span class="k"&gt;break&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

  &lt;span class="p"&gt;}&lt;/span&gt;

  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;hasSpecialChar&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nx"&gt;arrRules&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;arrRules&lt;/span&gt;

&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_1&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_2&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_3&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_4&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_5&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_6&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_7&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;validate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;password_8&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>javascript</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
