Skip to content

willowj/py_tricks

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

python trick packages

trick codes

​ Use JSON files as if they are python modules

​ 导入json 文件作为一个包使用

  • tester.json

    {
        "hello": "world",
        "this": {
            "can": {
                "be": "nested"
            }
        }
    }
    

    Now import jsonsempai and your json file!

    >>> from jsonsempai import magic
    >>> import tester
    >>> tester
    <module 'tester' from 'tester.json'>
    >>> tester.hello
    u'world'
    >>> tester.this.can.be
    u'nested'
    >>>

About

python tricks tools collections

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages