Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


  <h3 class="single-ellipsis">這是一個很長的標題超過一行就會隱藏,還包含 English text 可以再更多更多字,請再試試看,超過一行就會隱藏接下來的文字</h3>
  <p class="multiline-ellipsis">這是一段很長的段落文字至少超過兩行,還包含 English text 可以再更多更多更多更多字。這是一段很長的段落文字至少超過兩行,還包含 English text 可以更多更多更多更多字,請再試試看。請再試試看,超過五行就會隱藏接下來的文字。這是一段很長的段落文字至少超過兩行,還包含 English text 可以再更多更多字。</p>


                body {
  margin: 0;
  padding: 0;
  font: 100%/1.7 sans-serif;
  background: #eee;
:last-child {
  margin-bottom: 0;
article {
  margin: 40px auto;
  padding: 30px;
  max-width: 300px;
  background: #fff;
  box-shadow: 0 5px 15px rgba(0,0,0,.25);
h3 {
  margin: 0 0 .5em 0;
  line-height: 1.4;
.single-ellipsis {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
.multiline-ellipsis { 
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 5;
  overflow: hidden;
  /* line-clamp: 5; */
  display: flex;
  flex-direction: column;
  line-clamp: 5;
  overflow: hidden;