A Free Public API for Produce PLU Codes

When I built the app that allowed anyone to look up a Produce department item PLU code for use at self-checkouts by customers or for sign making by staff, I always wanted to put the data used into a public API so that individuals looking to make their own projects could make use of this data that I’ve collected.

Previously, all the data was stored in JavaScript objects – which is okay – but not great if you’re trying to build a more impressive project. The API data that I have made available is served up through NodeJS and Express and connects to a MongoDB database which now stores all the data.

The API only allows certain types of data to be delivered from the database – the database includes example pricing and this data is not sent out when the API is called.

The API can be accessed at https://gregrasmussen.com/store-system/public-plu-data and will be maintained at this location for some time to come. If you make use of it, please let me know – I’d be glad to check out your project and link to it as well 🙂

View more project posts in the Data category.

A&M Custom Creations – New Launch

Not too long ago, a longtime friend approached me knowing I’d been studying Web Development and asked me if I could help her launch her new Shopify store. Having had zero experience with Shopify, yet also wanting to be of assistance, and also being able to access and learn a new platform, I agreed, and began the design work and consultation for the Shopify page of A&M Custom Creations

First step: Building a site mock-up. I designed a rough idea of what the site could look like, and with a modification of the colour scheme, we had an idea of what the site should look like. Once it was approved, it was off to the second step: working on the code.

Building a Shopify theme isn’t just about making the current site look good, its about making sure the site looks good when the shop owner builds out a new section of his or her store, without needing to call you for assistance – it should work out of the box, so making sure that sticking to the correct variables when changing colour and font settings was paramount during the work modifying the existing theme. In addition, the shop owner requested additional options that allow customer requestions for product customization, which has been implemented through the creation of additional product templates.

A&M Custom Creations sells everything from t-shirts to key chains to backpack charms and customized mask clips. Give them a look, and them them Greg sent you 🙂

View more project posts in the Shopify category.

Shopping List & Integrated Store Navigation

When I was beginning to really sink my teeth into JavaScript, I, like many people, resorted to watching tutorials on YouTube and coded along with the videos as they were being presented. This is a great strategy when you’re learning, but not so great if you’d like to show prospective employers what you’re capable of. There are plenty of To-Do List videos on YouTube, but the To-Do List already exists – it doesn’t solve any new problems and all beginning developers have one. But what if the To-Do list could do more?

In order to learn the sorcery that is CSS element positioning, I constructed a mostly-accurate map of my current workplace, complete with aisle numbers to help with navigation. With this already constructed, I realized that a To-Do List – re-imagined as a Shopping List – and merged with the store map – could be something incredibly beneficial to many shoppers and businesses. All that would need to be done is merge the two projects into one, and create a way to search the map using your list.

Because at the time I was not making use of any databases, I created a CSS file with the co-ordinates for almost 400 items on the map, and each item name would be labelled as a class name in the CSS file. Once the list item is clicked, the page creates a new element directly overtop of where the item is in the store by calling the CSS class of the item name on the list.

Of course, only having a desktop version of this wouldn’t work too well in a store environment where you would be using a mobile device, so when the project was made responsive, the look changes – when held up in portrait view on your phone, only the list itself appears, and once the button to find the item is clicked, the user would turn the phone to landscape view, where the page view would change from a list to a map – with the arrow directly above the item. Once the user finds the item, they merely rotate the phone back to portrait orientation, cross out the item off their list, and continue on.

As an additional functionality for businesses – the page makes suggestions for products to add to the list, which change based on seasonality, day of the week, and month of the year. The user can dismiss these suggestions, or add them directly to the list.

This project also differs from any tutorial as it builds out the list from an array, rather than creating an element with each list item directly in the HTML code. It was my first somewhat-big endeavor in the web development field. It could use some upgrades, but I’m very proud of this piece, and if you shop at the store this is modeled after, I hope you find it useful.

View more project posts in the JavaScript category.

Personal Website WordPress Theme – 2020

When I initially built this website, I designed it using Adobe XD in such a way where my projects would have a short description along with a link to the project. However, in practice, this proved to be a bad idea – with only limited descriptions I was selling myself short on the work I’ve done. Creating more detailed posts would help profile my projects more in-depth, and expanding the projects page from a PHP file into a full WordPress installation made perfect sense.

The process itself was quite simple – WordPress installs take only a few minutes at most. Taking a blank underscores theme and implementing my site within it.. that was more of a challenge. I commented every template part and every page with the page name at its starting and ending points to see what code needed to go where, and before long, the site took shape as a theme. This, however, doesn’t unlock the full capability of what WordPress could do for me.

Enter the plugins – specifically Advanced Custom Fields. Once this was installed I added new header images and required links to GitHub repos and for the actual project page itself. I also installed the Font Awesome WordPress plugin and configured it to customize the post icon to the left side of the body text on larger screens, as well as provide a default icon option if desired.

WordPress also allowed me to categorize the posts in a very easy fashion. A later update of my personal website’s main page will allow any visitor to see my projects based on categories such as JavaScript, WordPress, React etc. – just by clicking those links to those categories on the main index page which WordPress has already set up for me.

The WordPress install at https://gregrasmussen.com/projects is no longer being updated, as I have migrated everything to the current site. Please continue to visit my current site at https://gregrasmussen.com/portfolio for up-to-date information on projects I’ve been putting out!

View more project posts in the WordPress category.

Blast from the HTML 4.0 Past

A long long time ago – over 15 years from the point of writing this post – before Font Awesome and CSS Animations and Mobile screens – I was already developing what we would now see as primitive websites. Back then, all you really needed to build something good was a decent WYSIWYG editor, good image software, and a little time and desire. If you wanted to go above and beyond, you learned a little bit of Flash to add to it as well.

Of course, now, you would look back at this personal website through the Wayback machine and it doesn’t match its mid-2000’s glory at all. The image of which has been edited since part of the site had a Flash animation displaying the site address on the page with animated radio waves appearing from the “r” logo moving to the right, and since Flash is at the end of its life cycle, cannot be shown. Several other graphics – which hold section names that can now be made by including web-based fonts in a <div> tag instead of the need to embed them in an image – are missing.

But if you look at the navigation – almost everything still works! Not only that – the colour scheme, the layout, some of the images – they still show off what worked back then. Even if the whole layout is table-based and used small transparent square images to hold spacing together the way it was supposed to be. There’s even a sidebar on the right side of the layout which held ads served up by Google Adsense – I still have around $12 USD in my account with them that the site created back then. Other iterations of this site included a section where I posted the class notes I typed up on my laptop in class so anyone who was sick or had to miss class was able to catch up easily, using a script that automatically displayed every file in my class notes directory on the site.

I forget how many versions of my personal site I built before I built this one. I still consider it my best design from those times. Even though back then I considered myself more of a designer than a developer, since JavaScriptSource.com was the place I got almost all my simple Javascripts and sourceforge.net allowed for guestbooks and polls and such, it was things like this that I truly enjoyed doing, and eventually knew I had to get back into doing.

Forgive this post for being more of a personal nature. It’s here for several reasons:

  • Yes – I’ve been building sites for a very long time – over 15 years now!
  • Follow your passions, for you may regret later on that you hadn’t, and take the challenge to learn to do something the right way.
  • Learn to do it well. What won’t kill you will make you stronger in the end.

View more project posts in the Throwback category.

Produce UPC/PLU Code Lookup Tool

Due to the nature of working in a supermarket produce department, I have encountered many instances where needing to know the PLU code (or price lookup code) was important. However, information for that is not readily available in many cases, and there was opportunity for me – a budding developer – to turn lemons into lemonade; to build an app that could tell you the code for said lemons, and all you had to do with type in the item’s name. And an app that would work just as well on a desktop or mobile screen.

But why stop there? Oftentimes, you don’t just need a single PLU code, but many, as signage needs to be frequently changed or replaced. If you had to look up an item’s code for a list, why should a user need to hold a mobile device in one hand, and write down the code to a list with another hand? To make it easier to make a list of codes, I created a method with which to add the looked-up PLU codes to a list, which could then be stored until the user requested a full listing of items. This list appears upon user request when they are ready to create the signs at the in-store computer workstation, and then disappears from memory once the user closes the list or navigates away from the page to ensure excess data doesn’t accumulate, and that extra signs are not made unnecessarily.

This project was built in March of 2020 and currently gets data from JavaScript Objects. A future version of this project incorporates this data into a far larger project with far more data and new ways to store data. Stay tuned for that one!

View more project posts in the JavaScript category.

COVID-19 Data Around The World

In April of 2020 – admittedly some of the earlier days of the current pandemic – I was eager to build my skills as a developer and incorporate an API into a new project. It hadn’t been my first time doing a project involving an API, but it was the first time where there would be no readily available tutorial on the subject of using this particular API for anything since the topic was so new at the time.

I decided that that was the time to build a project that allowed a user to select a country from a dropdown list of every affected country, with that data populated by looping through the country names in the API, to get further information on how the virus affected that nation in a pop-up modal, as well as to give the user information on the first 10 affected countries at a glance. This was achieved using CSS flexbox, allowing for responsive viewing across multiple screens.

This project still receives data daily as the pandemic spreads in some areas and eases in others. Overall, it serves as an informative project and makes an important addition to my portfolio.

View more project posts in the JavaScript category.

A Valentine’s Day Card

In February of 2020, in addition to a physical Valentine’s gift to a wonderful woman I’m fortunate to have, I decided to build her a digital extra.

The project starts with the image of a Mouse head – Mickey’s, that is, on a black background, pulsating with a brighter shade every few seconds. Once you move the computer mouse over the Mouse head elements, the Mouse head changes colours from grey to white, and scrolls down to the first of two slides which show random (and true) sentences that change on the screen at a rate of 20 sentences per second. Once you click each sentence, the cycling of multiple sentences stops, a setTimeout event happens which pops a Font Awesome icon onto the screen at the end of the sentence, and the site automatically scrolls down to the next slide.

This project was a smaller one – did not take long to build at all, but gave me experience with scrollIntoView, setInterval, setTimeout, and mouseover events, as well as randomizing the text that appears on screen. Colours were chosen with help from paletton.com, icons used are from the Font Awesome free icon collection, and design inspiration came from Mickey Mouse.

Also, she liked it 😀

View more project posts in the JavaScript category.