star

Tamil star-turned-neta Vijay to embark on statewide tour in Dec




star

Work for revival of Kolkata's iconic Adi Ganga to start from January




star

Gauff's perfect start to WTA Finals

World No. 3 Coco Gauff and No. 2 Iga Swiatek of Poland won their respective opening matches of the Orange Group at the WTA Finals Riyadh in Saudi Arabia.




star

MCD starts demolition drive in Bhalswa colony in north-west Delhi

The Municipal Corporation of Delhi on August 13 began a demolition drive in north-west Delhi's Bhalswa Dairy colony; heavy deployment of security personnel has been made at the site




star

Chess Olympiad | Hail the dazzling stars who have set the gold standard!

From Gukesh to Tania, the 10 brilliant Indian talents on display rose to the occasion, played their parts to perfection, and dominated the opposition to create history at Budapest




star

 Political instability, economic woes stare at Germany 

The German economy, the largest in Europe, has not been performing well and is looking at a second consecutive year of contraction; Germany was the only G-7 country to contract in 2024, with its economy expected to shrink by 0.2%




star

Magali Koenig : courir apres la pluie / direction editoriale, Geraldine Lay, Pierre Starobinski. [Accompagne de], Les yeux dans le samovar / Blaise Hofmann

[Arles] : Actes Sud, [2022]




star

Ag-coated tetrapod gold nanostars (Au@AgNSs) for acetamiprid determination in tea using SERS combined with microfluidics

Anal. Methods, 2024, Advance Article
DOI: 10.1039/D4AY00297K, Paper
Qian Ke, Limei Yin, Heera Jayan, Hesham R. El-Seedi, Xiaobo Zou, Zhiming Guo
The combination of highly sensitive SERS substrate core–shell Au@AgNSs and microfluidic chip featuring four circular split hybrid structures were used for quantitative detection of acetamiprid in tea. The LOD of acetamiprid was 0.048 ng mL−1.
To cite this article before page numbers are assigned, use the DOI form of citation above.
The content of this RSS Feed (c) The Royal Society of Chemistry




star

Meet capella star Alaa Wardi




star

Peravurani farmers’ market starts functioning




star

597: How Many VS Code Plugins, Poor Charlie’s Almanack, and Where to Start in 2024?

We're closing in on episode 600 and need your help to celebrate! Listen in to learn how to contribute to the episode. We're also talking GitHub desktop apps and code editors, how many VS Code plugins are needed, reading long form like Poor Charlie's Almanack, InVision shutting down, and answering our first Q of the year: how would you approach learning web development in 2024?




star

Start green, stay green

A recent CSE study found that many green-certified buildings were not eco-friendly after all. Deepa Sathiaram, executive director, En3 Sustainability Solutions, tells us what exactly goes wrong.




star

Startups join the party with craft mixers

How non-alcoholic mixers, handcrafted by small players, are edging out sugary soft drinks, sodas in cocktail glasses




star

A rising star in retirement planning

Amid a steadily swelling subscriber base, how the NPS can build on the momentum to reach its full potential




star

Bengaluru startup develops new tech for battery recycling, begins production

Li-ion battery recycler Metastable Materials launches commercial ops




star

Delhi govt. to start drive against burning of waste in open today

Delhi, neighbouring States likely to experience ‘very poor’ quality air over next 10 days, have placed the depts. concerned on high alert: Gopal Rai




star

How Star shone bright in India

A first-hand and in-depth account of the channel’s rise and the media business in India




star

Booming Digital Stars: 11 Inspiring Journeys from India’s Creator Economy 

Lessons from the exciting success stories of social media influencers




star

Start-up Compass: How Iconic Entrepreneurs got it Right

A relevant book for those about to embark on their entrepreneurial journey, or can serve as a useful resource for those who like to track the start-up ecosystem 




star

Blue Star Q4 net at Rs. 72 crore




star

S. Korea woos startups in India with ‘grand challenge’

Wants them to look at Korea as a testing bed for their ventures




star

RIL arm to invest $16 million in US tech startup NetraDyne




star

When you click upon a star




star

Startup Grex gets new CEO after founders squabble




star

Ikea to start production unit in India




star

Is Rajini just a southern star?

Ten days after Kabali ’s release, a look at how the film’s dubbed versions have fared




star

Muhurat trading: Sensex, Nifty advance to start Samvat 2081 on a high

Muhurat trading is a one-hour, symbolic trading session conducted by stock exchanges on the occasion of Diwali, marking the start of the new Samvat year.




star

Five-day special educator training programme to start from November 11

The initiative is being organised by Chennai Volunteers, a social initiative of the Giving Matters Foundation, a not-for-profit organisation, in collaboration with the Portobello Institute, Ireland




star

Kamal Haasan@70: Madras celebrates as its very own star




star

Deputy Chief Minister launches initiatives to support start-up ecosystem in T.N.

He also presents sanction letters for pre-incubation centres, which aim to support innovative business ideas in their initial stages




star

Optimality and cooperativity in superselective surface binding by multivalent DNA nanostars

Soft Matter, 2024, 20,8515-8523
DOI: 10.1039/D4SM00704B, Paper
Open Access
  This article is licensed under a Creative Commons Attribution 3.0 Unported Licence.
Christine Linne, Eva Heemskerk, Jos W. Zwanikken, Daniela J. Kraft, Liedewij Laan
Our study shows that DNA nanostars with three binding sites (ligands) can (1) bind superselectively to surfaces based on receptor density, and (2) that interactions between ligands affect the optimum number of ligands required for superselectivity.
The content of this RSS Feed (c) The Royal Society of Chemistry




star

It All Starts with a Humble <textarea>

Andy Bell rings out a fresh call in support of the timeless concept of progressive enhancement. What does it mean to build a modern JavaScript-focussed web experience that still works well if part of the stack isn’t supported or fails? Andy shows us how that might be done.


Those that know me well know that I make a lot of side projects. I most definitely make too many, but there’s one really useful thing about making lots of side projects: it allows me to experiment in a low-risk setting.

Side projects also allow me to accidentally create a context where I can demonstrate a really affective, long-running methodology for building on the web: progressive enhancement. That context is a little Progressive Web App that I’m tinkering with called Jotter. It’s incredibly simple, but under the hood, there’s a really solid experience built on top of a minimum viable experience which after reading this article, you’ll hopefully apply this methodology to your own work.

What is a minimum viable experience?

The key to progressive enhancement is distilling the user experience to its lowest possible technical solution and then building on it to improve the user experience. In the context of Jotter, that is a humble <textarea> element. That humble <textarea> is our minimum viable experience.

Let me show you how it’s built up, progressively real quick. If you disable CSS and JavaScript, you get this:

This result is great because I know that regardless of what happens, the user can do what they needed to do when the loaded Jotter in their browser: take some notes. That’s our minimum viable experience, completed with a few lines of code that work in every single browser—even very old browsers. Don’t you just love good ol’ HTML?

Now it’s time to enhance that minimum viable experience, progressively. It’s a good idea to do that in smaller steps rather than just provide a 0% experience or a 100% experience, which is the approach that’s often favoured by JavaScript framework enthusiasts. I think that process is counter-intuitive to the web, though, so building up from a minimum viable experience is the optimal way to go, in my opinion.

Understanding how a minimum viable experience works can be a bit tough, admittedly, so I like to use a the following diagram to explain the process:

Let me break down this diagram for both folks who can and can’t see it. On the top row, there’s four stages of a broken-up car, starting with just a wheel, all the way up to a fully functioning car. The car enhances only in a way that it is still mostly useless until it gets to its final form when the person is finally happy.

On the second row, instead of building a car, we start with a skateboard which immediately does the job of getting the person from point A to point B. This enhances to a Micro Scooter and then to a Push Bike. Its final form is a fancy looking Motor Scooter. I choose that instead of a car deliberately because generally, when you progressively enhance a project, it turns out to be way simpler and lighter than a project that was built without progressive enhancement in mind.

Now that we know what a minimum viable experience is and how it works, let’s apply this methodology to Jotter!

Add some CSS

The first enhancement is CSS. Jotter has a very simple design, which is mostly a full height <textarea> with a little sidebar. A flexbox-based, auto-stacking layout, inspired by a layout called The Sidebar is used and we’re good to go.

Based on the diagram from earlier, we can comfortably say we’re in Skateboard territory now.

Add some JavaScript

We’ve got styles now, so let’s enhance the experience again. A user can currently load up the site and take notes. If the CSS loads, it’ll be a more pleasant experience, but if they refresh their browser, they’re going to lose all of their work.

We can fix that by adding some local storage into the mix.

The functionality flow is pretty straightforward. As a user inputs content, the JavaScript listens to an input event and pushes the content of the <textarea> into localStorage. If we then set that localStorage data to populate the <textarea> on load, that user’s experience is suddenly enhanced because they can’t lose their work by accidentally refreshing.

The JavaScript is incredibly light, too:

const textArea = document.querySelector('textarea');
const storageKey = 'text';

const init = () => {

  textArea.value = localStorage.getItem(storageKey);

  textArea.addEventListener('input', () => {
    localStorage.setItem(storageKey, textArea.value);
  });
}

init();

In around 13 lines of code (which you can see a working demo here), we’ve been able to enhance the user’s experience considerably, and if we think back to our diagram from earlier, we are very much in Micro Scooter territory now.

Making it a PWA

We’re in really good shape now, so let’s turn Jotter into a Motor Scooter and make this thing work offline as an installable Progressive Web App (PWA).

Making a PWA is really achievable and Google have even produced a handy checklist to help you get going. You can also get guidance from a Lighthouse audit.

For this little app, all we need is a manifest and a Service Worker to cache assets and serve them offline for us if needed.

The Service Worker is actually pretty slim, so here it is in its entirety:

const VERSION = '0.1.3';
const CACHE_KEYS = {
  MAIN: `main-${VERSION}`
};

// URLS that we want to be cached when the worker is installed
const PRE_CACHE_URLS = ['/', '/css/global.css', '/js/app.js', '/js/components/content.js'];

/**
 * Takes an array of strings and puts them in a named cache store
 *
 * @param {String} cacheName
 * @param {Array} items=[]
 */
const addItemsToCache = function(cacheName, items = []) {
  caches.open(cacheName).then(cache => cache.addAll(items));
};

self.addEventListener('install', evt => {
  self.skipWaiting();

  addItemsToCache(CACHE_KEYS.MAIN, PRE_CACHE_URLS);
});

self.addEventListener('activate', evt => {
  // Look for any old caches that don't match our set and clear them out
  evt.waitUntil(
    caches
      .keys()
      .then(cacheNames => {
        return cacheNames.filter(item => !Object.values(CACHE_KEYS).includes(item));
      })
      .then(itemsToDelete => {
        return Promise.all(
          itemsToDelete.map(item => {
            return caches.delete(item);
          })
        );
      })
      .then(() => self.clients.claim())
  );
});

self.addEventListener('fetch', evt => {
  evt.respondWith(
    caches.match(evt.request).then(cachedResponse => {
      // Item found in cache so return
      if (cachedResponse) {
        return cachedResponse;
      }

      // Nothing found so load up the request from the network
      return caches.open(CACHE_KEYS.MAIN).then(cache => {
        return fetch(evt.request)
          .then(response => {
            // Put the new response in cache and return it
            return cache.put(evt.request, response.clone()).then(() => {
              return response;
            });
          })
          .catch(ex => {
            return;
          });
      });
    })
  );
});

What the Service Worker does here is pre-cache our core assets that we define in PRE_CACHE_URLS. Then, for each fetch event which is called per request, it’ll try to fulfil the request from cache first. If it can’t do that, it’ll load the remote request for us. With this setup, we achieve two things:

  1. We get offline support because we stick our critical assets in cache immediately so they will be accessible offline
  2. Once those critical assets and any other requested assets are cached, the app will run faster by default

Importantly now, because we have a manifest, some shortcut icons and a Service Worker that gives us offline support, we have a fully installable PWA!

Wrapping up

I hope with this simplified example you can see how approaching web design and development with a progressive enhancement approach, everyone gets an acceptable experience instead of those who are lucky enough to get every aspect of the page at the right time.

Jotter is very much live and in the process of being enhanced further, which you can see on its little in-app roadmap, so go ahead and play around with it.

Before you know it, it’ll be a car itself, but remember: it’ll always start as a humble little <textarea>.


About the author

Andy Bell is an independent designer and front-end developer who’s trying to make everyone’s experience on the web better with a focus on progressive enhancement and accessibility.

More articles by Andy




star

This Chennai-based startup customises your sneakers so you can put your personality on them

Pastels, bling, or bold colours, whatever be your taste, K-kix, a sneaker customisation platform from Chennai can do it for you



  • Life &amp; Style

star

From techno-inspired rave bags to pants that depict neurons, this Chennai-based gender neutral fashion label’s creations are conversation starters

Brimming with cut outs, panels, thread piping and embroidery, Biskit’s new collection explores the human mind



  • Life &amp; Style

star

Jumpstart: Sweating it out with Yoga

Yoga is often dissed by the younger generation as light, easy, slow exercise. BHUMIKA K. begs to differ after going through a ‘happy yoga’ class




star

How to start running




star

Jumpstart: Drumming up a fitness boost

Who would have thought that drumming would be a fun fitness workout? ALLAN MOSES RODRICKS drops the beat on the rhythmic regimen




star

A kickstart to self defence

There are ways to safeguard your physical and mental well being, say martial arts trainer Kyoshi K.S. Sekar and Krav Maga master S. Sreeram who will soon teach in Coimbatore




star

Five-Star Business Finance posts ₹268 cr profit in Q2, AUM grows 32%

For the quarter ended September 30, 2024, the company’s net profit surged by 34 per cent to ₹268 crore, up from ₹199 crore



  • Money &amp; Banking

star

Working toward a meaningful ‘victims’ register’ in Bastar

Compilation of the ‘register’, which has been tried globally as a conflict resolution tool, would have to an exercise in the spirit of truth and reconciliation




star

Field-level police personnel in DK, Udupi start using bodycams

“In addition to brining in transparency, the bodycams will make police personnel more conscious and improve their conduct with people,” Mangaluru Police Commissioner Anupam Agrawal said




star

IIITH's social incubator hosts roundtable on climate-tech startups




star

IndiaAI, Meta launch AI center in IIT Jodhpur; will promote student start-ups




star

Vistara to make last flight today before Air India merger

Vistara, a joint venture between Tata Group and Singapore Airlines, will fully merge with Air India, also owned by Tata Group




star

Kotigobba 2 review: A self-indulgent star vehicle




star

'Secret Superstar' quick review




star

Proptech start-up HouseEazy raises $7 mn in funding from Chiratae Ventures, others

Funds will be utilised to fuel company’s growth across NCR




star

When hope meets hurdles: stark reality of Telangana’s job market

The State’s job crisis has come back to haunt the Congress party, which rode to power last year on promises of employment. While local youth wait, worry, and exchange dreams about securing government jobs, short-term opportunities are drawing people from other States. This dynamic has transformed Telangana into a job magnet for outsiders but a desert for its own aspirants, reports Serish Nanisetti




star

NewGen stars have a chance to shine as Proteas challenge awaits 

It is imperative for them to shed the tag of sidekicks and establish themselves as the first-choice players in this format.




star

Hyperverge: An early start and growing

The startup company aims at solving the problem of photo organisation for smart-phone users.