New Patch, Merge?

    mazey-wordpress-utils
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.3 • Public • Published

    mazey-wordpress-utils

    NPM version l

    Wordpress utilities.

    Install

    You can get mazey-wordpress-utils via npm.

    npm install mazey-wordpress-utils --save
    

    Usage

    Hide Sidebar.

    import { hideSidebar } from 'mazey-wordpress-utils';
    
    hideSidebar({
      urlContainList: [ 'hide_sidebar' ], // It's a list for String in URL, `[ 'hide_sidebar' ]` is the default value.
    });
    

    Hide Header, the page will hide Header when it meets one of these two conditions:

    • Use WordPress Plugin Easy Table of Contents and open it in this page.
    • The page's URL is matched with one of the urlContainList.

    https://wordpress.org/plugins/easy-table-of-contents/

    import { hideHeaderInTOC } from 'mazey-wordpress-utils';
    
    hideHeaderInTOC({
      urlContainList: [ 'str1' ], // It's a list for String in URL, `[ 'urlContainListDefaultValue' ]` is the default value.
    });
    

    Develop

    # dev
    npm run dev
    
    # build
    npm run build
    
    # documentation
    npm run docs
    

    Install

    npm i mazey-wordpress-utils

    DownloadsWeekly Downloads

    2

    Version

    1.0.3

    License

    MIT

    Unpacked Size

    77.2 kB

    Total Files

    15

    Last publish

    Collaborators

    • mazeyqian