Option 1. Start the REPL as usual, wrap your code in an IIFE [2]:
> (function () { 'use strict'; 'abc'.length = 1 }()); TypeError: Cannot assign to read only property 'length'(Assigning to a read-only property fails silently in sloppy mode.)
Option 2. Use the Node.js command line option --use_strict:
node --use_strictAfterwards, everything you write in the REPL is interpreted in strict mode:
> 'abc'.length = 1 TypeError: Cannot assign to read only property 'length'
References: