Drupal 8: jQuery and Content Types

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
buddym's picture

Hey all,

I finally got around to installing Drupal 8! I like the built in responsive first Bartik theme, but there are a couple of other changes that are affecting my ability to add custom content to my new installation. The first is the removal of the php filter, and the second are the changes to the JavaScript API.

The removal of the php filter was a minor annoyance, but easily remedied by adding it to my installation. The changes to the JavaScript API however are proving to be my undoing.

Do any of you know how I can add jQuery to my content type postings? Previously, in Drupal 7 I would just add a reference to a jQuery library then inside script tags use one of these two calls:

(function ($)
{
    
})(jQuery);

jQuery(document).ready(function( $ )
{
  
});

This is no longer possible in Drupal 8, or so it seems. I keep getting a jQuery undefined ReferenceError. Any help would be greatly appreciated.

Cheers!

EDIT
Sorry, all is well with Drupal 8. Looks like I can still add jQuery inline with my content-type postings. I am not sure why this was such a struggle. All I needed was this call in my post:

<script type="text/javascript" src="/core/assets/vendor/jquery/jquery.js"></script>